/* public/css/styles.css */

/* =========================
   Brand Colors & Globals
   ========================= */

:root {
  /* Brand colors inspired by the product pack */
  --primary: #64a4c5;       /* teal/blue band */
  --primary-dark: #3c7d9b;  /* darker teal for hover */
  --accent: #555282;        /* deep indigo-purple band */
  --bg-dark: #22243d;       /* dark header/footer */
  --bg-light: #f5f7fb;      /* very light bluish background */
  --text-main: #1b1b23;
  --text-muted: #6f7285;
  --white: #ffffff;
  --max-width: 1100px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue",
    sans-serif;
  color: var(--text-main);
  background-color: #ffffff;
}

/* Layout Helper */

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* =========================
   Header & Navigation
   ========================= */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: linear-gradient(90deg, var(--accent) 0%, var(--primary) 100%);
  color: var(--white);
  backdrop-filter: blur(10px);
}

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

.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo {
  height: 65px;
  width: auto;
  object-fit: contain;
}

.brand-name {
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.9rem;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}

.nav a {
  margin-left: 1rem;
  text-decoration: none;
  color: var(--white);
  font-size: 0.9rem;
  opacity: 0.9;
}

.nav a:hover {
  opacity: 1;
}

/* Language switch */

.lang-switch {
  display: flex;
  gap: 0.35rem;
  font-size: 0.8rem;
  align-items: center;
}

.lang-switch a,
.lang-switch span {
  color: #ffffff;
  text-decoration: none;
  opacity: 0.85;
}

.lang-switch .lang-active {
  font-weight: 600;
  opacity: 1;
}

/* =========================
   Hero Section + Overlay
   ========================= */

.hero {
  position: relative;
  overflow: hidden;
  color: var(--white);
  padding: 3.5rem 0 3rem;
}

/* Gradient base */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  z-index: 0;
}

/* Product image overlay (same image as product) */
.hero::after {
  content: "";
  position: absolute;
  inset: -40px;
  background-image: url("/images/magnesium-flakes.jpg");
  background-size: cover;
  background-position: center;
  opacity: 0.25;              /* strength of the image */
  mix-blend-mode: soft-light;  /* lets gradient dominate */
  filter: blur(1.5px);
  z-index: 0;
}

.hero-inner {
  position: relative;
  z-index: 1; /* above overlay */
  display: flex;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.hero-text {
  flex: 1 1 280px;
}

.hero-text h1 {
  font-size: 2.4rem;
  margin-bottom: 0.75rem;
}

.hero-text p {
  margin-bottom: 1.5rem;
  max-width: 480px;
  color: #e5f3ff;
}

.hero-image-wrapper {
  flex: 1 1 260px;
  display: flex;
  justify-content: center;
}

.hero-image {
  max-width: 340px;
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  box-shadow: 0 24px 45px rgba(0, 0, 0, 0.55);
  object-fit: cover;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.4rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

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

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

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

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

.btn-full {
  width: 100%;
  justify-content: center;
}

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

.section {
  padding: 3rem 0;
  background-color: #ffffff;
}

.section-light {
  background-color: var(--bg-light);
}

.section-title {
  font-size: 1.8rem;
  margin: 0 0 0.3rem;
  text-align: center;
}

.section-subtitle {
  text-align: center;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

/* =========================
   Product Card (Home)
   ========================= */

.product-card {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: center;
  margin-top: 1rem;
}

.product-image-wrapper {
  flex: 1 1 260px;
  display: flex;
  justify-content: center;
}

.product-image {
  max-width: 320px;
  width: 100%;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.12);
}

.product-info {
  flex: 1 1 280px;
}

.product-info h3 {
  margin-top: 0;
  margin-bottom: 0.25rem;
}

.product-tagline {
  margin-top: 0;
  color: var(--text-muted);
}

.product-details {
  padding-left: 1.1rem;
  margin: 0.75rem 0 1rem;
  color: var(--text-main);
}

.product-price {
  margin-bottom: 1rem;
}

.price-main {
  font-weight: 600;
}

.price-note {
  display: block;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

/* =========================
   Lifestyle / Benefits
   ========================= */

.lifestyle-grid,
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.lifestyle-card,
.benefit-card {
  padding: 1.25rem;
  border-radius: 14px;
  background-color: #ffffff;
  border: 1px solid #dde3f1;
  box-shadow: 0 6px 16px rgba(23, 43, 77, 0.06);
}

.lifestyle-card h3,
.benefit-card h3 {
  margin-top: 0;
}

/* =========================
   How to Use
   ========================= */

.how-to-use ol {
  padding-left: 1.2rem;
}

.note {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.75rem;
}

/* =========================
   Contact section
   ========================= */

.contact-section {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: flex-start;
}

.contact-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.2rem;
}

/* Logo next to details box */
.contact-extra-wrapper {
  display: flex;
  align-items: center;   /* center vertically, natural heights */
  gap: 1rem;
}

.contact-logo-wrap {
  flex: 0 0 auto;
}

.contact-logo {
  width: 110px;          /* nice clean size */
  height: auto;
  object-fit: contain;
  border-radius: 14px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
}

.contact-extra {
  flex: 1 1 auto;
}


/* =========================
   Products Page Tiles
   ========================= */

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

.product-tile {
  background-color: #ffffff;
  border-radius: 14px;
  padding: 1.25rem;
  border: 1px solid #dde3f1;
  box-shadow: 0 6px 16px rgba(23, 43, 77, 0.06);
}

.product-tile-image {
  width: 100%;
  max-height: 220px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 0.75rem;
}

.product-tile-price {
  font-weight: 600;
  margin-top: 0.3rem;
}

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

.site-footer {
  background-color: var(--bg-dark);
  color: #e5e6f0;
  padding: 1.5rem 0;
  font-size: 0.85rem;
}

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

.footer-note {
  margin-top: 0.35rem;
  color: #b0b2c6;
}

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

@media (max-width: 768px) {
  .header-content {
    flex-wrap: wrap;
    gap: 0.75rem;
  }

.brand {
  display: flex;
  align-items: center;
  gap: 0.8rem; /* spacing between logo and text */
}

.brand-name {
  font-size: 1.2rem;   /* increase font to match bigger logo */
  font-weight: 700;
}

  .nav {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.5rem;
  }

  .nav a {
    margin-left: 0;
  }

  .hero {
    padding-top: 2.5rem;
  }

  .hero-text h1 {
    font-size: 2rem;
  }

  .product-card {
    flex-direction: column;
  }

  .contact-section {
    flex-direction: column;
  }
}

/* =========================
   RTL Tweaks (Arabic)
   ========================= */

html[dir="rtl"] body {
  direction: rtl;
}

html[dir="rtl"] .header-content {
  flex-direction: row-reverse;
}

html[dir="rtl"] .nav a {
  margin-left: 0;
  margin-right: 1rem;
}

html[dir="rtl"] .product-details {
  padding-left: 0;
  padding-right: 1.1rem;
}

/* Keep language switch aligned nicely in RTL too */
html[dir="rtl"] .lang-switch {
  flex-direction: row-reverse;
}

