/* ==========================================================================
   Golden Nest Farm - Modern Light Aesthetic CSS Design System
   ========================================================================== */

:root {
  /* Palette Tokens */
  --bg-primary: #fcfbfa;
  --bg-surface: #ffffff;
  --bg-surface-alt: #f7f4ef;
  --bg-accent-light: #fff8e8;
  
  --text-main: #2c2926;
  --text-muted: #6b645c;
  --text-light: #9c9389;

  --color-primary: #d97706;       /* Warm Amber */
  --color-primary-hover: #b45309;
  --color-secondary: #2e7d32;     /* Organic Green */
  --color-secondary-hover: #1b5e20;
  --color-accent: #f59e0b;        /* Golden Egg Yolk */
  
  --border-color: #e9e3da;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 16px 32px rgba(0, 0, 0, 0.1);

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;

  --font-family: 'Outfit', 'Inter', system-ui, -apple-system, sans-serif;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Styles */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-family: var(--font-family);
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.6;
}

body {
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Typography Helpers */
.section-tag {
  display: inline-block;
  padding: 6px 16px;
  background: var(--bg-accent-light);
  color: var(--color-primary);
  font-weight: 600;
  font-size: 0.875rem;
  border-radius: var(--radius-full);
  margin-bottom: 12px;
  border: 1px solid rgba(217, 119, 6, 0.2);
}

.section-title {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto 40px auto;
}

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

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background: var(--color-primary);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(217, 119, 6, 0.3);
}

.btn-primary:hover {
  background: var(--color-primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(217, 119, 6, 0.4);
}

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

.btn-outline:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: var(--bg-accent-light);
}

.lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: var(--bg-surface-alt);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  font-family: var(--font-family);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-main);
  cursor: pointer;
  transition: var(--transition);
  min-width: 68px;
  justify-content: center;
}

.lang-btn:hover {
  background: var(--bg-accent-light);
  border-color: var(--color-primary);
}

#langTextContainer {
  font-family: var(--font-family);
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1;
}

/* Header & Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(252, 251, 250, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(233, 227, 218, 0.6);
  padding: 16px 0;
  transition: var(--transition);
}

.nav-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--text-main);
  white-space: nowrap;
  flex-shrink: 0;
}

.brand-icon {
  width: 36px;
  height: 36px;
  background: var(--color-accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 14px;
  list-style: none;
  flex-wrap: wrap;
  justify-content: center;
}

.nav-link {
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--text-muted);
  transition: var(--transition);
  white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
  color: var(--color-primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-main);
}

/* Layout Containers */
.section {
  padding: 90px 24px;
}

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

/* Hero Section */
.hero-section {
  padding-top: 140px;
  padding-bottom: 90px;
  background: linear-gradient(180deg, #fffdf8 0%, var(--bg-primary) 100%);
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.hero-title {
  font-size: 3rem;
  line-height: 1.15;
  font-weight: 800;
  margin-top: 12px;
  margin-bottom: 20px;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-img-wrapper {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.hero-img-wrapper img {
  width: 100%;
  height: 440px;
  object-fit: cover;
  transition: var(--transition);
}

.hero-img-wrapper:hover img {
  transform: scale(1.03);
}

/* Feature Cards Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  margin-top: 40px;
}

.feature-card {
  background: var(--bg-surface);
  padding: 32px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-primary);
}

.feature-icon {
  width: 56px;
  height: 56px;
  background: var(--bg-accent-light);
  color: var(--color-primary);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 20px;
}

/* History Section */
.history-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.stats-row {
  display: flex;
  gap: 28px;
  margin-top: 28px;
}

.stat-item {
  border-left: 3px solid var(--color-primary);
  padding-left: 16px;
}

.stat-number {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--color-primary);
}

.stat-label {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Products Section */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 32px;
}

.product-card {
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

.product-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--color-secondary);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: var(--radius-full);
}

.product-img {
  height: 220px;
  object-fit: cover;
  width: 100%;
}

.product-content {
  padding: 24px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Egg Facts Section */
.facts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
}

.fact-card {
  background: var(--bg-surface-alt);
  padding: 28px;
  border-radius: var(--radius-md);
  border: 1px dashed var(--border-color);
}

/* Announcements */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
}

.news-card {
  background: var(--bg-surface);
  padding: 28px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.news-date {
  font-size: 0.85rem;
  color: var(--color-primary);
  font-weight: 600;
  margin-bottom: 8px;
}

/* Photo Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  height: 220px;
  box-shadow: var(--shadow-sm);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.gallery-item:hover img {
  transform: scale(1.08);
}

/* Contact & Map Section */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.contact-info-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 24px;
}

.contact-info-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.contact-icon {
  width: 44px;
  height: 44px;
  background: var(--bg-accent-light);
  color: var(--color-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.map-container {
  width: 100%;
  height: 380px;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
}

.map-container iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

/* Form Styles */
.custom-form {
  background: var(--bg-surface);
  padding: 32px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-main);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: var(--font-family);
  font-size: 1rem;
  background: var(--bg-primary);
  color: var(--text-main);
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.1);
}

.form-alert {
  padding: 16px;
  border-radius: var(--radius-sm);
  margin-bottom: 24px;
  font-weight: 500;
  display: none;
}

.form-success {
  background: #e8f5e9;
  color: #1b5e20;
  border: 1px solid #c8e6c9;
}

.form-error {
  background: #ffebee;
  color: #b71c1c;
  border: 1px solid #ffcdd2;
}

.fs-error-msg {
  display: block;
  color: #b71c1c;
  font-size: 0.85rem;
  margin-top: 4px;
  min-height: 1.2em;
}

/* Footer */
footer {
  background: #1e1b18;
  color: #d5cfc7;
  padding: 48px 24px;
  text-align: center;
  border-top: 1px solid #332e29;
}

/* Responsive Media Queries */
@media (max-width: 1100px) {
  .nav-menu {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    background: var(--bg-surface);
    flex-direction: column;
    padding: 24px;
    box-shadow: var(--shadow-lg);
    display: none;
    border-bottom: 1px solid var(--border-color);
  }

  .nav-menu.open {
    display: flex;
  }

  .mobile-toggle {
    display: block;
  }
}

@media (max-width: 900px) {
  .hero-grid, .history-grid, .contact-grid {
    grid-template-columns: 1fr;
  }
  
  .hero-title {
    font-size: 2.25rem;
  }
}
