/*
 * almada-brand.css
 * Al Mada Brand Design System
 * Exact layout styles ported from al-mada-preview.html
 */

@import url('https://fonts.googleapis.com/css2?family=Amiri:ital,wght@0,400;0,700;1,400&family=Tajawal:wght@300;400;500;700&display=swap');

.almada-container {
  font-family: var(--global-body-font-family);
  color: var(--almada-text-dark);
  background: var(--almada-bg-main);
  direction: rtl; 
  overflow-x: hidden;
  line-height: 1.6;
}

/* Force sections to break out of boxed WordPress containers */
.almada-breakout {
  width: 100vw !important;
  max-width: 100vw !important;
  margin-left: calc(50% - 50vw) !important;
  margin-right: calc(50% - 50vw) !important;
  position: relative;
}

/* ---------------------- */
/* ANIMATIONS & REVEALS   */
/* ---------------------- */
.reveal {
  opacity: 0;
  transform: translateY(50px);
  transition: all 1s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }

@keyframes morphShape {
  0%   { border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%; }
  34%  { border-radius: 70% 30% 50% 50% / 30% 30% 70% 70%; }
  67%  { border-radius: 100% 60% 60% 100% / 100% 100% 60% 60%; }
  100% { border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%; }
}

@keyframes spinSlow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(50%); }
}

/* ---------------------- */
/* SECTIONS               */
/* ---------------------- */
.almada-section {
  padding: 120px 5vw;
  position: relative;
  z-index: 2;
}

/* ---------------------- */
/* IMMERSIVE HERO         */
/* ---------------------- */
.almada-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 120px 8vw 60px 8vw; /* Extra padding top/bottom to center card safely */
  overflow: hidden;
}

.almada-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-size: cover;
  background-position: center top;
  background-attachment: fixed; 
}

.almada-hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  /* Milky beige overlay on the left fading to clear on the right */
  background: linear-gradient(to right, rgba(249, 246, 240, 0.7) 0%, rgba(249, 246, 240, 0.1) 100%);
}

.almada-hero-badge {
  position: absolute;
  top: 30vh; /* Pushed down slightly to align with the new content height */
  left: 8vw;
  width: 140px;
  height: 140px;
  z-index: 5;
  animation: spinSlow 15s linear infinite;
  pointer-events: none;
  opacity: 0.9;
}

.almada-hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 600px;
  padding: 20px 50px;
  background: rgba(249, 246, 240, 0.4);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 40px;
  box-shadow: 0 30px 60px rgba(0,0,0,0.1);
  margin: auto 0;
  text-align: right;
  align-self: center;
  height: max-content;
}

.almada-tag {
  font-size: 14px;
  font-weight: 700;
  color: var(--almada-olive);
  letter-spacing: 2px;
  margin: 0 auto 24px auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-transform: uppercase;
}
.almada-tag::before,
.almada-tag::after {
  content: '';
  display: block;
  width: 30px;
  height: 2px;
  background: var(--almada-olive);
}

.almada-h1 {
  font-family: var(--global-heading-font-family);
  font-size: clamp(40px, 4.5vw, 64px);
  line-height: 1.1;
  color: var(--almada-text-dark);
  margin: 0 0 20px;
  font-weight: 700;
}
.almada-h1 em {
  color: var(--almada-accent);
  font-style: italic;
  font-weight: 400;
}

.almada-p {
  font-size: 16px;
  line-height: 1.8;
  color: #4A5541;
  margin: 0 0 40px;
  font-weight: 400;
}

.almada-hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

.almada-btn {
  background: var(--almada-olive);
  color: var(--almada-text-light);
  border: 1px solid var(--almada-olive);
  padding: 18px 44px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  justify-content: center;
  align-items: center;
  font-family: var(--global-body-font-family);
  cursor: pointer;
  overflow: hidden;
  position: relative;
}
.almada-btn::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  background: rgba(255,255,255,0.1);
  top: 0;
  left: -100%;
  transform: skewX(-45deg);
  transition: all 0.4s ease;
}
.almada-btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 30px rgba(90, 107, 71, 0.25);
  color: var(--almada-text-light);
}
.almada-btn:hover::after {
  left: 100%;
}

.almada-btn-outline {
  background: transparent;
  color: var(--almada-text-dark);
  border: 1px solid rgba(44, 51, 37, 0.2);
}
.almada-btn-outline:hover {
  background: var(--almada-bg-main);
  color: var(--almada-olive);
  border-color: var(--almada-bg-main);
}

/* ---------------------- */
/* INFINITE MARQUEE       */
/* ---------------------- */
.almada-marquee-wrapper {
  background: var(--almada-olive);
  color: var(--almada-text-light);
  padding: 24px 0;
  overflow: hidden;
  display: flex;
  white-space: nowrap;
  border-top: 1px solid rgba(255,255,255,0.1);
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.almada-marquee {
  display: inline-flex;
  gap: 40px;
  animation: marquee 30s linear infinite;
  padding-right: 40px;
}
.almada-marquee-item {
  font-family: var(--global-heading-font-family);
  font-size: 24px;
  font-weight: 400;
  display: inline-flex;
  align-items: center;
  gap: 16px;
}
.almada-marquee-icon {
  font-size: 28px;
}

/* ---------------------- */
/* SECTION HEADERS        */
/* ---------------------- */
.almada-section-header {
  text-align: center;
  margin-bottom: 80px;
}
.almada-eyebrow {
  font-size: 15px;
  color: var(--almada-accent);
  letter-spacing: 2px;
  font-weight: 700;
  margin-bottom: 16px;
  display: block;
  text-transform: uppercase;
}
.almada-h2 {
  font-family: var(--global-heading-font-family);
  font-size: clamp(40px, 5vw, 64px);
  color: var(--almada-text-dark);
  margin: 0;
  line-height: 1.1;
}
.almada-h2 em {
  color: var(--almada-olive);
  font-style: italic;
}

/* ---------------------- */
/* PRODUCTS (Woo Mockup)  */
/* ---------------------- */
.almada-products {
  background: var(--almada-bg-main);
}
.woocommerce ul.products {
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
  gap: 40px; 
  list-style: none; 
  padding: 0; 
  margin: 0;
}
.woocommerce ul.products li.product {
  background: #FFF;
  border-radius: 20px;
  padding: 24px;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  text-align: center;
  border: 1px solid rgba(0,0,0,0.03);
  position: relative;
  overflow: hidden;
}

.woocommerce ul.products li.product:hover {
  transform: translateY(-12px);
  box-shadow: 0 30px 60px rgba(0,0,0,0.06);
  border-color: rgba(90, 107, 71, 0.15);
}

.woocommerce ul.products li.product img {
  margin-bottom: 24px;
  aspect-ratio: 1;
  object-fit: cover;
  width: 100%;
  border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
  animation: morphShape 8s ease-in-out infinite both alternate;
  transition: transform 0.5s ease;
}

.woocommerce ul.products li.product:nth-child(2) img {
  animation-delay: -2s;
}
.woocommerce ul.products li.product:nth-child(3) img {
  animation-delay: -4s;
}

.woocommerce ul.products li.product:hover img {
  transform: scale(1.05) rotate(2deg);
}

.woocommerce-loop-product__title {
  font-family: var(--global-heading-font-family);
  font-size: 24px;
  color: var(--almada-text-dark);
  margin-bottom: 12px;
  margin-top: 0;
}
.price {
  color: var(--almada-olive);
  font-weight: 700;
  font-size: 20px;
  font-family: var(--global-body-font-family);
  display: block;
  margin-bottom: 16px;
}

.almada-btn-wrapper {
  text-align: center;
  margin-top: 80px;
}

/* ---------------------- */
/* DYNAMIC STORY SECTION  */
/* ---------------------- */
.almada-story {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--almada-text-dark);
  color: var(--almada-bg-main);
  align-items: center;
  overflow: hidden;
}
.almada-story-img-wrapper {
  position: relative;
  height: 100%;
  min-height: 500px;
  overflow: hidden;
}
.almada-story-img-wrapper img {
  width: 100%;
  height: 120%; 
  object-fit: cover;
  position: absolute;
  top: -10%;
  left: 0;
  transform: translateZ(0); 
  transition: transform 0.5s ease;
}
.almada-story:hover .almada-story-img-wrapper img {
  transform: scale(1.05);
}

.almada-story-content {
  padding: 60px 8vw;
  position: relative;
}
.almada-story-content .almada-h2 {
  color: var(--almada-bg-main);
}
.almada-story-content .almada-h2 em {
  color: #D3C3A3;
}
.almada-story-p {
  font-size: 19px;
  line-height: 2;
  color: rgba(249, 246, 240, 0.85);
  margin: 40px 0 50px;
  font-weight: 300;
}

.almada-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px 32px;
}
.almada-feature {
  display: flex;
  gap: 20px;
}
.almada-feature-icon {
  width: 60px;
  height: 60px;
  background: rgba(90, 107, 71, 0.3);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  flex-shrink: 0;
  transition: transform 0.3s ease;
}
.almada-feature:hover .almada-feature-icon {
  transform: rotate(10deg) scale(1.1);
}
.almada-feature-title {
  font-family: var(--global-heading-font-family);
  font-size: 24px;
  margin-bottom: 8px;
  color: var(--almada-bg-main);
}
.almada-feature-desc {
  font-size: 16px;
  color: rgba(249, 246, 240, 0.65);
  line-height: 1.7;
}

/* ---------------------- */
/* NEWSLETTER             */
/* ---------------------- */
.almada-newsletter {
  background: var(--almada-bg-alt);
  text-align: center;
  padding: 150px 5vw;
  position: relative;
}
.almada-newsletter-inner {
  max-width: 600px;
  margin: 0 auto;
  background: rgba(255,255,255,0.6);
  padding: 60px;
  border-radius: 30px;
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.5);
  box-shadow: 0 40px 80px rgba(0,0,0,0.03);
}
.almada-form {
  display: flex;
  gap: 12px;
  margin-top: 40px;
}
.almada-input {
  flex: 1;
  padding: 20px 24px;
  border: 2px solid transparent;
  background: #FFF;
  border-radius: 50px;
  font-family: var(--global-body-font-family);
  font-size: 16px;
  outline: none;
  transition: all 0.3s;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}
.almada-input:focus {
  border-color: var(--almada-olive);
  box-shadow: 0 0 0 4px rgba(90, 107, 71, 0.1);
}

/* Decorative SVG Branch */
.almada-bg-branch {
  position: absolute;
  width: 600px;
  height: 600px;
  opacity: 0.03;
  pointer-events: none;
  z-index: 1;
}
.almada-bg-branch.top-right {
  top: -150px;
  right: -150px;
  transform: rotate(30deg);
}
.almada-bg-branch.bottom-left {
  bottom: -100px;
  left: -150px;
  transform: rotate(-150deg);
}

/* Responsive */
@media (max-width: 992px) {
  .almada-hero {
    min-height: auto;
    padding: 120px 5vw;
  }
  .almada-hero-content {
    padding: 40px;
  }
  .almada-story {
    grid-template-columns: 1fr;
  }
  .almada-story-img-wrapper {
    min-height: 50vh;
  }
  .almada-hero-badge {
    display: none; 
  }
}
@media (max-width: 576px) {
  .almada-features {
    grid-template-columns: 1fr;
  }
  .almada-form {
    flex-direction: column;
  }
  .almada-newsletter-inner {
    padding: 40px 20px;
  }
}