/* ============================================
   Botanical Alchemist Studio - Main Stylesheet
   ============================================ */

:root {
  /* Color Palette - Natural Dye Inspired */
  --color-primary: #a8423c; /* Madder Root Crimson */
  --color-secondary: #1c2957; /* Indigo Deep Night */
  --color-accent: #ddad37; /* Turmeric Gold Wash */
  --color-neutral: #7f7556; /* Olive Leaf Umber */
  --color-background: #f4eee3; /* Pressed Herb Cream */
  --color-accent-soft: #b97c91; /* Mulberry Ink Mist */
  
  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 2rem;
  --space-xl: 3rem;
  --space-xxl: 4rem;
  
  /* Typography */
  --font-heading: 'Cormorant Garamond', serif;
  --font-body: 'Inter', sans-serif;
  
  /* Borders & Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --border-width: 1px;
  --border-style: solid;
  
  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(28, 41, 87, 0.1);
  --shadow-md: 0 4px 8px rgba(28, 41, 87, 0.15);
  --shadow-lg: 0 8px 16px rgba(28, 41, 87, 0.2);
  
  /* Transitions */
  --transition-fast: 0.3s ease;
  --transition-medium: 0.5s ease;
  --transition-slow: 0.8s ease;
  
  /* Layout */
  --container-max-width: 1200px;
  --header-height: 80px;
}

/* ============================================
   Reset & Base Styles
   ============================================ */

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-secondary);
  background-color: var(--color-background);
  overflow-x: hidden;
}

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

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition-fast);
}

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

ul, ol {
  list-style: none;
}

/* ============================================
   Typography
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
  color: var(--color-secondary);
  margin-bottom: var(--space-md);
}

h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
}

h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

h4 {
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
}

p {
  margin-bottom: var(--space-md);
}

/* ============================================
   Layout Components
   ============================================ */

.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);

}
.hero-section .container {
  width: 100%;
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
    display: flex;
    justify-content: center;
}

.section {
  padding: var(--space-xl) 0;
}

.section-alt {
  background-color: rgba(168, 66, 60, 0.05);
  padding: var(--space-xl) 0;
}

/* ============================================
   Header
   ============================================ */

.site-header {
  background: linear-gradient(135deg, rgba(244, 238, 227, 0.95) 0%, rgba(244, 238, 227, 0.98) 100%);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  position: relative;
  z-index: 1000;
  transition: transform var(--transition-medium);
}

.site-header.hidden {
  transform: translateY(-100%);
}

.header-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md) var(--space-md);
  min-height: var(--header-height);
  width: 100%;
}

@media (max-width: 768px) {
  .header-wrapper {
    padding: var(--space-sm) var(--space-md);
  }
}

.brand-name {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  color: var(--color-primary);
  letter-spacing: 0.05em;
}

/* ============================================
   Navigation
   ============================================ */

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 30px;
  background: transparent;
  z-index: 1001;
  cursor: pointer;
}

.nav-toggle span {
  width: 100%;
  height: 2px;
  background-color: var(--color-secondary);
  transition: all var(--transition-fast);
  transform-origin: center;
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(8px, 8px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

.main-nav {
  position: static;
  width: auto;
  height: auto;
  background: transparent;
  box-shadow: none;
  transition: none;
  z-index: auto;
  overflow: visible;
  padding: 0;
}

.main-nav.active {
  right: auto;
}

.nav-list {
  display: flex;
  flex-direction: row;
  gap: var(--space-lg);
  align-items: center;
}

.nav-link {
  font-size: 1rem;
  color: var(--color-secondary);
  padding: var(--space-sm) 0;
  border-bottom: 2px solid transparent;
  transition: all var(--transition-fast);
  display: inline-block;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--color-primary);
  border-bottom-color: var(--color-primary);
}

/* Mobile Navigation */
@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .main-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    max-width: 80vw;
    height: 100vh;
    background: linear-gradient(135deg, var(--color-background) 0%, rgba(244, 238, 227, 0.98) 100%);
    box-shadow: var(--shadow-lg);
    transition: right var(--transition-medium);
    z-index: 1000;
    overflow-y: auto;
    padding: var(--space-xxl) var(--space-lg);
  }

  .main-nav.active {
    right: 0;
  }

  .nav-list {
    flex-direction: column;
    gap: var(--space-lg);
    align-items: flex-start;
  }

  .nav-link {
    font-size: 1.1rem;
  }
  
  .brand-name {
    font-size: clamp(1.25rem, 4vw, 1.5rem);
  }
}

/* ============================================
   Hero Section
   ============================================ */

.hero-section {
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xxl) var(--space-md);
  overflow: hidden;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(28, 41, 87, 0.4) 0%, rgba(168, 66, 60, 0.4) 100%);
  z-index: 1;
}

.hero-content {
  text-align: center;
  max-width: 800px;
  position: relative;
  z-index: 2;
  padding: var(--space-lg);
}

.hero-title {
  margin-bottom: var(--space-lg);
  color: white;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-description {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: var(--space-xl);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.hero-section .btn {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

/* ============================================
   Image Gallery
   ============================================ */

.image-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
  padding: var(--space-xl) 0;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.gallery-image {
  width: 100%;
  height: auto;
  display: block;
}

.herbarium-frame {
  border: 3px solid var(--color-neutral);
  border-radius: var(--radius-md);
  padding: var(--space-sm);
  background-color: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-md);
}

/* ============================================
   Content Sections
   ============================================ */

.content-block {
  margin-bottom: var(--space-xl);
}

.section-title {
  text-align: center;
  margin-bottom: var(--space-xl);
  position: relative;
  padding-bottom: var(--space-md);
}

.section-title::after {
  content: '🌿';
  display: block;
  font-size: 1.5rem;
  margin-top: var(--space-sm);
  opacity: 0.6;
}

.text-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  font-size: clamp(1rem, 2vw, 1.125rem);
  line-height: 1.8;
}

.content-block {
  margin-bottom: var(--space-xl);
  width: 100%;
  max-width: 100%;
}

.content-block.text-center,
.content-block .text-center {
  text-align: center;
}

.two-column {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-xl);
  align-items: center;
}

/* ============================================
   Cards
   ============================================ */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
  margin: var(--space-xl) 0;
}

.card {
  background: rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-fast);
  border: 1px solid rgba(127, 117, 86, 0.2);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary);
}

.card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-md);
}

.card-title {
  font-size: 1.5rem;
  margin-bottom: var(--space-sm);
  color: var(--color-primary);
}

.card-text {
  color: var(--color-neutral);
  margin-bottom: var(--space-md);
}

/* ============================================
   Buttons
   ============================================ */

.btn {
  display: inline-block;
  padding: var(--space-md) var(--space-xl);
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  cursor: pointer;
  border: 2px solid transparent;
}

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

.btn-primary:hover {
  background-color: var(--color-secondary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background-color: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.btn-secondary:hover {
  background-color: var(--color-primary);
  color: white;
}

.btn-center {
  display: block;
  text-align: center;
  margin: var(--space-xl) auto;
  max-width: 200px;
}

/* ============================================
   Forms
   ============================================ */

.form-container {
  max-width: 600px;
  margin: var(--space-xl) auto;
  background: rgba(255, 255, 255, 0.9);
  padding: var(--space-xl);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  margin-bottom: var(--space-sm);
  font-weight: 500;
  color: var(--color-secondary);
}

.form-input,
.form-textarea {
  width: 100%;
  padding: var(--space-md);
  border: 2px solid rgba(127, 117, 86, 0.3);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color var(--transition-fast);
  background-color: white;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--color-primary);
}

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

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  margin-top: var(--space-md);
}

.checkbox-input {
  margin-top: 4px;
  width: 18px;
  height: 18px;
  cursor: pointer;
}

.checkbox-label {
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--color-neutral);
}

.form-submit {
  width: 100%;
  margin-top: var(--space-lg);
}

/* ============================================
   Footer
   ============================================ */

.site-footer {
  background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-primary) 100%);
  color: white;
  padding: var(--space-xl) 0 var(--space-md);
  margin-top: var(--space-xxl);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-xl);
  margin-bottom: var(--space-lg);
}

.footer-section h4 {
  color: white;
  margin-bottom: var(--space-md);
}

.footer-menu {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer-link {
  color: rgba(255, 255, 255, 0.9);
  transition: color var(--transition-fast);
}

.footer-link:hover {
  color: var(--color-accent);
}

.footer-bottom {
  text-align: center;
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
}

/* ============================================
   Privacy Popup
   ============================================ */

.privacy-popup {
  position: fixed;
  bottom: -400px;
  left: 0;
  right: 0;
  background: rgba(28, 41, 87, 0.98);
  color: white;
  padding: var(--space-xl);
  box-shadow: var(--shadow-lg);
  z-index: 2000;
  transition: bottom var(--transition-medium);
  max-width: 600px;
  margin: 0 auto;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.privacy-popup.show {
  bottom: 0;
}

.privacy-content {
  margin-bottom: var(--space-lg);
}

.privacy-actions {
  display: flex;
  gap: var(--space-md);
  justify-content: flex-end;
}

/* ============================================
   Map Container
   ============================================ */

.map-container {
  width: 100%;
  height: 400px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  margin: var(--space-xl) 0;
}

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

/* ============================================
   Special Pages
   ============================================ */

.thank-you-message {
  text-align: center;
  padding: var(--space-xxl) var(--space-md);
  max-width: 600px;
  margin: var(--space-xxl) auto;
}

.error-page {
  text-align: center;
  padding: var(--space-xxl) var(--space-md);
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.error-code {
  font-size: clamp(4rem, 10vw, 8rem);
  color: var(--color-primary);
  font-weight: 700;
  margin-bottom: var(--space-md);
}

/* ============================================
   Herbarium Style (Dye Library)
   ============================================ */

.herbarium-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-xl);
  padding: var(--space-xl) 0;
}

.herbarium-card {
  background: rgba(255, 255, 255, 0.95);
  border: 3px solid var(--color-neutral);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  box-shadow: var(--shadow-md);
  position: relative;
}

.herbarium-card::before {
  content: '';
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  height: 2px;
  background: repeating-linear-gradient(
    to right,
    transparent,
    transparent 10px,
    var(--color-neutral) 10px,
    var(--color-neutral) 12px
  );
}

.plant-name {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  color: var(--color-primary);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
  font-style: italic;
}

.specimen-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  margin: var(--space-md) 0;
}

.specimen-details {
  display: grid;
  gap: var(--space-sm);
  font-size: 0.95rem;
  color: var(--color-neutral);
}

.detail-row {
  display: flex;
  justify-content: space-between;
  padding: var(--space-xs) 0;
  border-bottom: 1px dotted rgba(127, 117, 86, 0.3);
}

.detail-label {
  font-weight: 600;
  color: var(--color-secondary);
}

/* ============================================
   Technique Diagrams
   ============================================ */

.technique-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-xl);
  padding: var(--space-xl) 0;
}

.technique-card {
  background: rgba(255, 255, 255, 0.9);
  padding: var(--space-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.technique-card::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(168, 66, 60, 0.1) 0%, transparent 70%);
  animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.6; }
}

.technique-icon {
  font-size: 3rem;
  text-align: center;
  margin-bottom: var(--space-md);
}

.technique-title {
  font-size: 1.5rem;
  color: var(--color-primary);
  margin-bottom: var(--space-md);
  text-align: center;
}

.technique-steps {
  list-style: none;
  padding-left: 0;
}

.technique-steps li {
  padding: var(--space-sm) 0;
  padding-left: var(--space-lg);
  position: relative;
  color: var(--color-neutral);
}

.technique-steps li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--color-accent);
  font-weight: bold;
}

/* ============================================
   Color Story Cards
   ============================================ */

.story-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--space-xl);
  padding: var(--space-xl) 0;
}

.story-card {
  background: rgba(255, 255, 255, 0.95);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-fast);
}

.story-card:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

.story-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.story-content {
  padding: var(--space-lg);
}

.story-title {
  font-size: 1.75rem;
  color: var(--color-primary);
  margin-bottom: var(--space-md);
}

.story-text {
  color: var(--color-neutral);
  line-height: 1.8;
  margin-bottom: var(--space-md);
}

.color-badge {
  display: inline-block;
  padding: var(--space-xs) var(--space-md);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  margin-top: var(--space-sm);
}

/* ============================================
   Products Grid
   ============================================ */

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-xl);
  padding: var(--space-xl) 0;
}

.product-card {
  background: rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-fast);
}

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

.product-image {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.product-info {
  padding: var(--space-lg);
}

.product-title {
  font-size: 1.5rem;
  color: var(--color-primary);
  margin-bottom: var(--space-sm);
}

.product-description {
  color: var(--color-neutral);
  margin-bottom: var(--space-md);
}

.product-price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-secondary);
  margin-top: var(--space-md);
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 768px) {
  :root {
    --header-height: 70px;
  }
  
  .container {
    padding: 0 var(--space-sm);
  }
  
  .two-column {
    grid-template-columns: 1fr;
  }
  
  .hero-section {
    min-height: 50vh;
  }
  
  .nav-list {
    gap: var(--space-md);
  }
  
  .nav-link {
    font-size: 0.9rem;
  }
  
  .privacy-popup {
    padding: var(--space-lg);
    max-width: 100%;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }
  
  .privacy-actions {
    flex-direction: column;
  }
  
  .footer-content {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    text-align: center;
  }
  
  .hero-content {
    padding: var(--space-md);
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 var(--space-sm);
  }
  
  .section {
    padding: var(--space-lg) 0;
  }
  
  .image-gallery,
  .card-grid,
  .herbarium-grid,
  .technique-grid,
  .story-grid,
  .products-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }
  
  .form-container {
    padding: var(--space-lg);
  }
  
  .map-container {
    height: 300px;
  }
}

@media (max-width: 320px) {
  html {
    font-size: 14px;
  }
  
  .btn {
    padding: var(--space-sm) var(--space-lg);
    font-size: 0.9rem;
  }
}

/* ============================================
   Utility Classes
   ============================================ */

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

.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }

.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }

.hidden {
  display: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

