/* =============================================
   MINERAQUA - Modern Corporate Website
   ============================================= */

/* --- CSS Variables --- */
:root {
  --color-primary: #1a5276;
  --color-primary-light: #2980b9;
  --color-primary-dark: #0d2b3e;
  --color-accent: #a8d8ea;
  --color-accent-light: #d4ecf7;
  --color-gold: #c9a84c;
  --color-text: #1a1a2e;
  --color-text-light: #5a5a7a;
  --color-bg: #ffffff;
  --color-bg-alt: #f8fafb;
  --color-bg-dark: #0a1628;
  --color-border: #e8edf2;

  --font-heading: 'Playfair Display', 'Georgia', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-accent: 'Cormorant Garamond', 'Georgia', serif;

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;

  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 8px 30px rgba(0,0,0,0.08);
  --shadow-lg: 0 20px 60px rgba(0,0,0,0.12);
  --shadow-glow: 0 0 40px rgba(41, 128, 185, 0.15);

  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.7;
  overflow-x: hidden;
}

/* RTL support for Arabic */
html[dir="rtl"] body {
  direction: rtl;
  text-align: right;
}

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

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

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

.section {
  padding: 120px 0;
  position: relative;
}

/* --- Loader --- */
.loader {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: var(--color-bg-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

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

.loader-drop {
  animation: loaderBounce 1.2s ease-in-out infinite;
}

@keyframes loaderBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-20px); }
}

.loader-text {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: white;
  letter-spacing: 8px;
  margin-top: 20px;
  opacity: 0.8;
}

/* --- Navigation --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 20px 0;
  transition: all var(--transition);
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 12px 0;
  box-shadow: var(--shadow-sm);
}

.navbar.scrolled .nav-link {
  color: var(--color-text);
}

.navbar.scrolled .nav-logo {
  color: var(--color-text);
}

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

.nav-logo {
  color: white;
  flex-shrink: 0;
}

.logo-svg {
  height: 40px;
  width: auto;
}

/* Scroll progress indicator */
.scroll-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: rgba(255, 255, 255, 0.08);
  z-index: 10;
}

.navbar.scrolled .scroll-progress {
  background: rgba(0, 0, 0, 0.06);
}

.scroll-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--color-primary-light), var(--color-accent));
  transition: width 0.05s linear;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  font-size: 0.85rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
  white-space: nowrap;
  letter-spacing: 0.3px;
}

.nav-link:hover,
.nav-link.active {
  color: white;
  background: rgba(255, 255, 255, 0.1);
}

.navbar.scrolled .nav-link:hover,
.navbar.scrolled .nav-link.active {
  color: var(--color-primary);
  background: rgba(26, 82, 118, 0.08);
}

/* Language Selector */
.lang-selector {
  position: relative;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-sm);
  color: white;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all var(--transition);
}

.navbar.scrolled .lang-btn {
  background: rgba(26, 82, 118, 0.05);
  border-color: var(--color-border);
  color: var(--color-text);
}

.lang-btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

.navbar.scrolled .lang-btn:hover {
  background: rgba(26, 82, 118, 0.1);
}

.lang-flag {
  font-size: 1.1rem;
}

.lang-arrow {
  transition: transform var(--transition);
}

.lang-selector.open .lang-arrow {
  transform: rotate(180deg);
}

.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: white;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  min-width: 180px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all var(--transition);
  overflow: hidden;
  z-index: 100;
}

.lang-selector.open .lang-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang-option {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 12px 18px;
  border: none;
  background: none;
  color: var(--color-text);
  font-size: 0.9rem;
  cursor: pointer;
  transition: background var(--transition);
  text-align: left;
}

.lang-option:hover {
  background: var(--color-bg-alt);
}

.lang-option.active {
  background: rgba(26, 82, 118, 0.08);
  color: var(--color-primary);
  font-weight: 600;
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1001;
}

.hamburger span {
  width: 24px;
  height: 2px;
  background: white;
  border-radius: 2px;
  transition: all var(--transition);
}

.navbar.scrolled .hamburger span {
  background: var(--color-text);
}

.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* --- Hero Section --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--color-bg-dark);
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(26, 82, 118, 0.6) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(41, 128, 185, 0.4) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(168, 216, 234, 0.2) 0%, transparent 40%),
    linear-gradient(180deg, #0a1628 0%, #1a3a5c 40%, #1a5276 70%, #0a1628 100%);
}

.hero-particles {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 120px 24px 140px; /* WHY: Extra bottom padding to prevent overlap with scroll indicator */
  max-width: 900px;
}

.hero-badge {
  display: inline-block;
  padding: 8px 24px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50px;
  color: var(--color-accent);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 2px;
  margin-bottom: 32px;
  backdrop-filter: blur(10px);
}

.hero-title {
  color: white;
  margin-bottom: 24px;
}

.hero-title-line {
  display: block;
  font-family: var(--font-body);
  font-size: 1.2rem;
  font-weight: 300;
  letter-spacing: 4px;
  text-transform: uppercase;
  opacity: 0.7;
  margin-bottom: 8px;
}

.hero-title-accent {
  display: block;
  font-family: var(--font-heading);
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 600;
  line-height: 1.1;
  background: linear-gradient(135deg, #ffffff 0%, #a8d8ea 50%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.8;
}

.hero-ctas {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 80px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all var(--transition);
  cursor: pointer;
  border: none;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary-light), var(--color-primary));
  color: white;
  box-shadow: 0 4px 20px rgba(41, 128, 185, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(41, 128, 185, 0.4);
}

.btn-outline {
  background: transparent;
  color: white;
  border: 1.5px solid rgba(255, 255, 255, 0.3);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.6);
  transform: translateY(-2px);
}

.btn-full {
  width: 100%;
}

.btn-game {
  background: linear-gradient(135deg, #0984e3, #6c5ce7);
  color: white;
  width: 100%;
  font-size: 1rem;
  padding: 16px;
  box-shadow: 0 4px 20px rgba(108, 92, 231, 0.3);
}

.btn-game:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(108, 92, 231, 0.4);
}

/* Hero Stats */
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 60px;
  padding-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

.hero-stat-number {
  display: block;
  font-family: var(--font-heading);
  font-size: 2.8rem;
  font-weight: 700;
  color: white;
  line-height: 1.2;
}

.hero-stat-label {
  display: block;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-top: 4px;
}

/* Scroll indicator */
.hero-scroll {
  position: absolute;
  bottom: 20px; /* WHY: Moved lower to avoid overlap with hero stats */
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  text-align: center;
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.75rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.scroll-indicator {
  width: 24px;
  height: 40px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  margin: 10px auto 0;
  position: relative;
}

.scroll-indicator::after {
  content: '';
  width: 4px;
  height: 8px;
  background: var(--color-accent);
  border-radius: 2px;
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollBounce 2s ease-in-out infinite;
}

@keyframes scrollBounce {
  0%, 100% { top: 6px; opacity: 1; }
  50% { top: 22px; opacity: 0.3; }
}

/* --- Section Headers --- */
.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 80px;
}

.section-header.light .section-title,
.section-header.light .section-desc {
  color: white;
}

.section-header.light .section-tag {
  color: var(--color-accent);
  border-color: var(--color-accent);
}

.section-tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--color-primary-light);
  border: 1.5px solid var(--color-primary-light);
  padding: 6px 20px;
  border-radius: 50px;
  margin-bottom: 24px;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 600;
  color: var(--color-text);
  line-height: 1.3;
  margin-bottom: 20px;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--color-text-light);
  line-height: 1.8;
}

/* --- About Section --- */
.about {
  background: var(--color-bg-alt);
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-bottom: 80px;
}

.about-card {
  background: white;
  padding: 40px 28px;
  border-radius: var(--radius-lg);
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  border: 1px solid var(--color-border);
}

.about-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-accent);
}

.about-card-icon {
  margin-bottom: 20px;
}

.about-card h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--color-primary-dark);
}

.about-card p {
  font-size: 0.9rem;
  color: var(--color-text-light);
  line-height: 1.7;
}

.about-company {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-company-text h3 {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  color: var(--color-primary-dark);
  margin-bottom: 20px;
}

.about-company-text p {
  color: var(--color-text-light);
  margin-bottom: 16px;
  line-height: 1.8;
}

/* --- History Timeline --- */
.history {
  background: var(--color-bg);
}

.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  padding: 20px 0;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  background: linear-gradient(180deg, transparent, var(--color-primary-light), var(--color-accent), var(--color-primary-light), transparent);
  transform: translateX(-50%);
}

.timeline-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 48px;
  position: relative;
}

.timeline-item:nth-child(odd) {
  justify-content: flex-start;
  padding-right: calc(50% + 40px);
  text-align: right;
}

.timeline-item:nth-child(even) {
  justify-content: flex-end;
  padding-left: calc(50% + 40px);
}

.timeline-marker {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 16px;
  height: 16px;
  background: var(--color-primary-light);
  border: 3px solid white;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(41, 128, 185, 0.2);
  z-index: 1;
}

.timeline-content {
  background: white;
  padding: 28px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  transition: all var(--transition);
}

.timeline-content:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--color-accent);
}

.timeline-year {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--color-primary-light);
  margin-bottom: 8px;
}

.timeline-content h3 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--color-primary-dark);
}

.timeline-content p {
  font-size: 0.9rem;
  color: var(--color-text-light);
  line-height: 1.7;
}

/* --- Brands Section --- */
.brands {
  background: var(--color-bg-alt);
}

.brands-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.brand-card {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: all var(--transition-slow);
  background: #ffffff;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--color-border);
}

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

.brand-card-bg {
  display: none; /* WHY: Replaced solid bg with split layout (white top + colored bottom) */
}

.brand-card-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* WHY: Pure white background so JPG bottle images blend seamlessly */
/* WHY: No border/bg distinction - entire card is white so bottles blend perfectly */
.brand-bottles {
  padding: 32px 24px;
  text-align: center;
  background: #ffffff;
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-bottles img {
  max-height: 190px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 8px 24px rgba(0,0,0,0.12));
  transition: transform 0.4s ease;
}

.brand-bottles img:hover {
  transform: scale(1.06);
}

.brand-bottles-double {
  display: flex;
  gap: 16px;
  justify-content: center;
  align-items: center;
}

.brand-bottles-double img {
  max-height: 170px;
}

.brand-logo-area {
  margin-bottom: 8px;
}

.brand-logo-area svg text {
  fill: var(--color-primary-dark) !important; /* WHY: Dark text on white card instead of white */
}

/* WHY: Info section same white background as bottles for seamless look */
.brand-info {
  padding: 0 28px 32px;
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #ffffff;
}

.brand-tagline {
  font-family: var(--font-accent);
  font-size: 0.95rem;
  font-style: italic;
  color: var(--color-primary-light);
  margin-bottom: 12px;
  letter-spacing: 1px;
}

.brand-desc {
  font-size: 0.88rem;
  line-height: 1.8;
  color: var(--color-text-light);
  flex: 1;
  margin-bottom: 24px;
}

.brand-features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.brand-features span {
  padding: 5px 12px;
  background: rgba(26, 82, 118, 0.06);
  border: 1px solid rgba(26, 82, 118, 0.15);
  border-radius: 50px;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  color: var(--color-primary);
}

.brand-link {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--color-primary-light);
  transition: all var(--transition);
  align-self: flex-start;
  margin-top: auto;
}

.brand-link:hover {
  color: var(--color-primary-dark);
  transform: translateX(4px);
}

/* --- Sustainability Section --- */
.sustainability {
  background: var(--color-bg-dark);
  position: relative;
  overflow: hidden;
}

.sustainability-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 50%, rgba(41, 128, 185, 0.15) 0%, transparent 60%),
    radial-gradient(ellipse at 70% 30%, rgba(168, 216, 234, 0.1) 0%, transparent 50%);
}

.policy-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}

.policy-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  padding: 36px 24px;
  text-align: center;
  transition: all var(--transition);
  backdrop-filter: blur(10px);
}

.policy-card:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--color-accent);
  transform: translateY(-4px);
}

.policy-icon {
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.policy-card h3 {
  font-family: var(--font-heading);
  font-size: 1rem;
  color: white;
  margin-bottom: 12px;
}

.policy-card p {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.6;
}

/* --- Games Section --- */
.games {
  background: var(--color-bg);
  overflow: hidden;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.game-card {
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: white;
  box-shadow: var(--shadow-md);
  transition: all var(--transition);
  border: 1px solid var(--color-border);
}

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

.game-card-preview {
  padding: 48px 28px;
  text-align: center;
  color: white;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.game-emoji {
  font-size: 3rem;
  margin-bottom: 16px;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.2));
}

.game-card-preview h3 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  margin-bottom: 8px;
}

.game-card-preview p {
  font-size: 0.85rem;
  opacity: 0.85;
  max-width: 250px;
}

.game-card .btn-game {
  border-radius: 0;
}

/* Game Modal */
.game-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.game-modal.active {
  display: flex;
}

.game-modal-content {
  background: white;
  border-radius: var(--radius-xl);
  max-width: 700px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  padding: 40px;
}

.game-modal-close {
  position: absolute;
  top: 16px;
  right: 20px;
  background: none;
  border: none;
  font-size: 2rem;
  cursor: pointer;
  color: var(--color-text-light);
  transition: color var(--transition);
  z-index: 1;
}

.game-modal-close:hover {
  color: var(--color-text);
}

/* --- Distributor Section --- */
.distributor {
  background: var(--color-bg);
}

.distributor-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 60px;
  align-items: flex-start;
}

.distributor-info .section-tag { margin-bottom: 16px; }
.distributor-info .section-title { margin-bottom: 12px; }
.distributor-info .section-desc { margin-bottom: 8px; }

.distributor-form-wrapper {
  background: white;
  padding: 36px;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--color-border);
}

.distributor-form-wrapper select:focus {
  outline: none;
  border-color: var(--color-primary-light);
  box-shadow: 0 0 0 4px rgba(41, 128, 185, 0.1);
  background: white;
}

@media (max-width: 1024px) {
  .distributor-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .distributor-form-wrapper {
    padding: 20px;
  }
  .distributor-form-wrapper [style*="grid-template-columns: 1fr 1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }
  .distributor-form-wrapper [style*="grid-template-columns:1fr 1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }
}

/* --- Team Section --- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.team-card {
  text-align: center;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: white;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  transition: all var(--transition);
}

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

.team-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: #eef3f7;
}

/* WHY: Placeholder initials for team members without photos */
.team-placeholder {
  width: 100%;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-light));
  color: white;
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: 2px;
}

.team-info {
  padding: 14px 12px 18px;
}

.team-info h3 {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 3px;
  line-height: 1.3;
}

.team-info p {
  font-size: 0.72rem;
  color: var(--color-primary-light);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

@media (max-width: 1024px) {
  .team-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 768px) {
  .team-grid { grid-template-columns: repeat(3, 1fr); gap: 12px; }
}

@media (max-width: 480px) {
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .team-info h3 { font-size: 0.8rem; }
}

/* --- Blog Cards --- */
.blog-card:hover {
  transform: translateY(-6px) !important;
  box-shadow: var(--shadow-lg) !important;
  border-color: var(--color-accent) !important;
}

@media (max-width: 768px) {
  #blogGrid { grid-template-columns: 1fr !important; max-width: 450px; margin: 0 auto; }
}

/* --- FAQ Section --- */
.faq-item {
  border-bottom: 1px solid var(--color-border);
}

.faq-question {
  width: 100%;
  padding: 22px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: none;
  border: none;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text);
  cursor: pointer;
  text-align: left;
  gap: 16px;
  transition: color var(--transition);
}

.faq-question:hover {
  color: var(--color-primary-light);
}

.faq-icon {
  font-size: 1.4rem;
  font-weight: 300;
  color: var(--color-primary-light);
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-item.active .faq-answer {
  max-height: 300px;
}

.faq-answer p {
  padding: 0 0 20px;
  font-size: 0.92rem;
  color: var(--color-text-light);
  line-height: 1.8;
}

.faq-answer a {
  color: var(--color-primary-light);
  text-decoration: underline;
}

/* --- Mineral Bars --- */
.mineral-bar-container {
  margin-bottom: 16px;
}

.mineral-bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  margin-bottom: 6px;
  color: var(--color-text);
}

.mineral-bar-label span:last-child {
  font-weight: 700;
  color: var(--color-primary);
}

.mineral-bar-track {
  height: 8px;
  background: #eef3f7;
  border-radius: 4px;
  overflow: hidden;
}

.mineral-bar-fill {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--color-primary-light), var(--color-accent));
  width: 0%;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.mineral-bar-fill.gold {
  background: linear-gradient(90deg, #f39c12, #f1c40f);
}

/* --- Contact Section --- */
.contact {
  background: var(--color-bg-alt);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}

.contact-info .section-tag {
  margin-bottom: 16px;
}

.contact-info .section-title {
  text-align: left;
  margin-bottom: 12px;
}

.contact-info .section-desc {
  text-align: left;
  margin-bottom: 40px;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

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

.contact-icon {
  font-size: 1.5rem;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(26, 82, 118, 0.08);
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

.contact-item strong {
  display: block;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--color-text-light);
  margin-bottom: 4px;
}

.contact-item a {
  color: var(--color-primary);
  font-weight: 500;
}

.contact-item a:hover {
  color: var(--color-primary-light);
}

/* Contact Form */
.contact-form-wrapper {
  background: white;
  padding: 40px;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--color-border);
}

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

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

/* WHY: Visible borders always, not just on focus - so users see the fields clearly */
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 14px 18px;
  border: 1.5px solid #c0c8d2;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--color-text);
  background: #ffffff;
  transition: all var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--color-primary-light);
  box-shadow: 0 0 0 4px rgba(41, 128, 185, 0.1);
  background: white;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #a0aab4;
}

.form-check {
  display: flex;
  align-items: center;
  gap: 10px;
}

.form-check input[type="checkbox"] {
  width: auto;
  accent-color: var(--color-primary);
}

.form-check label {
  margin-bottom: 0;
  font-weight: 400;
  font-size: 0.85rem;
}

/* --- Footer --- */
.footer {
  background: var(--color-bg-dark);
  color: rgba(255, 255, 255, 0.7);
  padding: 80px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-brand p {
  margin-top: 20px;
  font-size: 0.9rem;
  line-height: 1.7;
  max-width: 300px;
}

.footer-links h4 {
  color: white;
  font-family: var(--font-heading);
  font-size: 1rem;
  margin-bottom: 20px;
}

.footer-links a,
.footer-links span {
  display: block;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 10px;
  transition: color var(--transition);
}

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

.footer-bottom {
  padding-top: 32px;
  text-align: center;
  font-size: 0.85rem;
  opacity: 0.5;
}

/* --- Animations (AOS-like) --- */
[data-aos] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-aos="fade-up"].aos-animate {
  opacity: 1;
  transform: translateY(0);
}

[data-aos="fade-right"] {
  transform: translateX(-30px);
}

[data-aos="fade-right"].aos-animate {
  opacity: 1;
  transform: translateX(0);
}

[data-aos="fade-left"] {
  transform: translateX(30px);
}

[data-aos="fade-left"].aos-animate {
  opacity: 1;
  transform: translateX(0);
}

[data-aos="zoom-in"] {
  transform: scale(0.9);
}

[data-aos="zoom-in"].aos-animate {
  opacity: 1;
  transform: scale(1);
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .about-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .brands-grid {
    grid-template-columns: 1fr;
    max-width: 500px;
    margin: 0 auto;
  }

  .policy-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .timeline-item:nth-child(odd),
  .timeline-item:nth-child(even) {
    padding-left: 50px;
    padding-right: 0;
    text-align: left;
    justify-content: flex-start;
  }

  .timeline::before {
    left: 0;
  }

  .timeline-marker {
    left: 0;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 80px 0;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 22, 40, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    z-index: 999;
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links .nav-link {
    font-size: 1.2rem;
    color: white;
    padding: 12px 24px;
  }

  .hamburger {
    display: flex;
  }

  .hero-stats {
    flex-direction: column;
    gap: 24px;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .about-company {
    grid-template-columns: 1fr;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .games-grid {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin: 0 auto;
  }

  .policy-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .brand-card {
    min-height: 400px;
  }

  .game-modal-content {
    padding: 24px;
    margin: 10px;
  }
}

@media (max-width: 480px) {
  .policy-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-ctas {
    flex-direction: column;
    align-items: center;
  }

  .contact-form-wrapper {
    padding: 24px;
  }

  .brand-bottles-double {
    flex-direction: column;
  }
}

/* --- Smooth transitions & performance --- */
/* WHY: GPU-accelerated animations for smoother scrolling on mobile */
.about-card,
.brand-card,
.policy-card,
.game-card,
.gallery-item,
.timeline-content {
  will-change: transform;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

/* WHY: Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .water-particle, .wave { display: none; }
}

/* --- Focus states for keyboard accessibility --- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 3px solid var(--color-primary-light);
  outline-offset: 2px;
  border-radius: 4px;
}

/* --- Smooth hover lift effect for all cards --- */
.about-card,
.brand-card,
.game-card,
.policy-card {
  transform: translateY(0) translateZ(0);
}

/* --- Loading skeleton for images --- */
.gallery-item img,
.brand-bottles img,
.about-company-image img {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.gallery-item img[src],
.brand-bottles img[src],
.about-company-image img[src] {
  animation: none;
  background: none;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* --- Better text selection --- */
::selection {
  background: var(--color-accent);
  color: var(--color-primary-dark);
}

/* --- Scroll padding for fixed navbar --- */
html {
  scroll-padding-top: 80px;
}

/* --- Print styles --- */
@media print {
  .navbar, .hero-particles, .hero-waves, .hero-scroll, .games, .game-modal, .loader { display: none !important; }
  .section { padding: 30px 0; }
  body { color: #000; background: #fff; }
  a { color: #000; }
}

/* --- Water Drop Particle styles --- */
.water-particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: rgba(168, 216, 234, 0.4);
  border-radius: 50%;
  pointer-events: none;
  animation: floatUp linear infinite;
}

@keyframes floatUp {
  0% { transform: translateY(0) scale(1); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 0.3; }
  100% { transform: translateY(-100vh) scale(0.5); opacity: 0; }
}

/* --- Water Wave Animation --- */
.hero-waves {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 40%;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}

.wave {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 200%; /* WHY: Double width so the wave can scroll horizontally for seamless loop */
  height: 100%;
}

.wave-1 { animation: waveMove 12s linear infinite; }
.wave-2 { animation: waveMove 16s linear infinite reverse; bottom: -20px; }
.wave-3 { animation: waveMove 20s linear infinite; bottom: -40px; }

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

/* --- Gallery Grid --- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 250px;
  gap: 16px;
}

.gallery-large {
  grid-column: span 2;
  grid-row: span 2;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

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

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.6) 0%, transparent 60%);
  display: flex;
  align-items: flex-end;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.gallery-overlay span {
  color: white;
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 500;
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 200px;
  }
  .gallery-large {
    grid-column: span 2;
    grid-row: span 1;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: 200px;
  }
  .gallery-large {
    grid-column: span 1;
  }
}
