/*
 * Global stylesheet for EmpowerHer Crafts website.
 *
 * The colour palette draws on warm neutrals and soft pastels as
 * recommended in the project brief – beige, dusty pink, bamboo green
 * and warm orange – to convey a feeling of handmade warmth and
 * feminine energy【407956085884721†L18-L19】.  The typography is set in
 * Quicksand and Noto Sans SC for bilingual support.  Layouts are
 * responsive using CSS grid and flexbox.
 */

/* Import Google Fonts for English and Chinese text. */
@import url('https://fonts.googleapis.com/css2?family=Quicksand:wght@400;500;700&family=Noto+Sans+SC:wght@400;500;700&display=swap');

:root {
  /* colour variables */
  --color-primary: #f5eae2; /* soft beige */
  --color-secondary: #fce8e3; /* light rose */
  --color-accent: #a8bfa0;    /* bamboo green */
  --color-highlight: #efa880; /* warm orange */
  --color-text: #333333;
  --color-light-text: #666666;
  --nav-height: 64px;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: 'Quicksand', 'Noto Sans SC', sans-serif;
  line-height: 1.6;
  background-color: var(--color-primary);
  color: var(--color-text);
}

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

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: var(--color-primary);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* Navigation bar styling */
.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-height);
}

.site-logo {
  font-weight: 700;
  font-size: 1.4rem;
  color: var(--color-highlight);
  display: flex;
  align-items: center;
}

.site-logo i {
  margin-right: 0.5rem;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.nav-links a {
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--color-highlight);
}

/* Language toggle */
.lang-switch {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.lang-switch button {
  background: none;
  border: none;
  font-size: 0.9rem;
  padding: 0.25rem 0.5rem;
  cursor: pointer;
  border-radius: 4px;
  transition: background-color 0.2s;
}

.lang-switch button.active {
  background-color: var(--color-highlight);
  color: white;
}

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

/* Hero section */
.hero {
  position: relative;
  /* Use new blue‑green weaving‑inspired background that coordinates with product images */
  /* Updated hero background to coordinate with product images using original texture */
  background-image: url('assets/banner-coord4.jpg');
  background-size: cover;
  background-position: center;
  color: #422c2b;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  height: 60vh;
  padding: 2rem 1rem;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(2px);
}

.hero-content {
  position: relative;
  max-width: 700px;
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  font-weight: 700;
}

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

.cta-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.cta-buttons a {
  padding: 0.75rem 1.5rem;
  border-radius: 30px;
  font-weight: 600;
  color: white;
  background-color: var(--color-highlight);
  transition: background-color 0.2s;
}

.cta-buttons a.secondary {
  background-color: var(--color-accent);
}

.cta-buttons a:hover {
  filter: brightness(0.9);
}

/* Product cards grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.product-card {
  background-color: var(--color-secondary);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
  height: 100%;
}

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

.product-card .card-body {
  padding: 1rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
  font-weight: 600;
}

.product-card p {
  flex: 1;
  font-size: 0.9rem;
  color: var(--color-light-text);
}

.product-card .price {
  font-weight: 700;
  margin-top: 0.5rem;
}

.product-card a {
  margin-top: 0.8rem;
  align-self: flex-start;
  padding: 0.5rem 1rem;
  background-color: var(--color-highlight);
  color: white;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  transition: filter 0.2s;
}

.product-card a:hover {
  filter: brightness(0.92);
}

/* Buttons inside product cards (e.g. detail page) should inherit
   the same styling as links for consistency. */
.product-card button {
  margin-top: 0.8rem;
  align-self: flex-start;
  padding: 0.5rem 1rem;
  background-color: var(--color-highlight);
  color: white;
  border: none;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.2s;
}

.product-card button:hover {
  filter: brightness(0.92);
}

/* Filter section */
.filters {
  margin-bottom: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  background-color: var(--color-secondary);
  padding: 1rem;
  border-radius: 8px;
}

.filters label {
  font-weight: 600;
  margin-right: 0.5rem;
}

.filters select,
.filters input[type="number"],
.filters input[type="range"] {
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  border: 1px solid #ccc;
  font-family: inherit;
}

/* Story cards */
.story-section {
  margin-top: 3rem;
}

.story-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.story-card {
  background-color: var(--color-secondary);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.story-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
}

.story-card .card-body {
  padding: 1rem;
}

.story-card h4 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

/* Testimonials */
.testimonials {
  margin-top: 3rem;
}

.testimonial-item {
  background-color: var(--color-secondary);
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.testimonial-item .stars {
  color: var(--color-highlight);
  margin-bottom: 0.5rem;
}

/* About page */
.about-section {
  margin-bottom: 2rem;
}

.about-section h2 {
  font-size: 1.6rem;
  margin-bottom: 0.5rem;
  color: var(--color-highlight);
}

.about-section p {
  font-size: 1rem;
  margin-bottom: 1rem;
  color: var(--color-text);
}

.achievements {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 1.5rem;
}

.achievement {
  flex: 1;
  min-width: 200px;
  background-color: var(--color-secondary);
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.achievement h3 {
  margin: 0;
  font-size: 2rem;
  color: var(--color-highlight);
}

.achievement p {
  margin: 0.2rem 0 0;
  color: var(--color-light-text);
  font-size: 0.9rem;
}

/* Impact page */
.impact-overview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.impact-card {
  background-color: var(--color-secondary);
  border-radius: 8px;
  padding: 1rem;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.impact-card h3 {
  margin: 0;
  font-size: 1.8rem;
  color: var(--color-highlight);
}

.impact-card p {
  margin: 0.3rem 0 0;
  font-size: 0.9rem;
  color: var(--color-light-text);
}

.chart-container {
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}

/* Empower page */
.training-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 1rem;
}

.training-item {
  background-color: var(--color-secondary);
  border-radius: 8px;
  padding: 1rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.training-item h4 {
  margin: 0;
  font-size: 1.1rem;
}

.training-item p {
  margin: 0.5rem 0 0;
  font-size: 0.9rem;
  color: var(--color-light-text);
}

/* Contact / Join page */
.contact-form {
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-form input,
.contact-form textarea {
  padding: 0.75rem;
  border-radius: 4px;
  border: 1px solid #ccc;
  font-family: inherit;
}

.contact-form button {
  padding: 0.75rem;
  border: none;
  border-radius: 4px;
  background-color: var(--color-highlight);
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.2s;
}

.contact-form button:hover {
  filter: brightness(0.9);
}

/* Account page */
.account-container {
  max-width: 500px;
  margin: 0 auto;
  background-color: var(--color-secondary);
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.account-container h2 {
  margin-top: 0;
  color: var(--color-highlight);
}

.account-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.account-form input {
  padding: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-family: inherit;
}

.account-form button {
  padding: 0.75rem;
  border: none;
  border-radius: 4px;
  background-color: var(--color-highlight);
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.2s;
}

.account-form button:hover {
  filter: brightness(0.9);
}

/* Footer */
footer {
  background-color: var(--color-secondary);
  padding: 1rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--color-light-text);
}