/* =============================================
   MUSKAN ERP - Main Stylesheet
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Poppins:wght@400;500;600;700;800&display=swap');

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

:root {
  --primary: #f59e0b;
  --primary-dark: #d97706;
  --accent: #10b981;
  --dark-bg: #0a1628;
  --dark-card: #0f1f3d;
  --dark-card2: #162040;
  --border-color: #1e3a5f;
  --text-light: #e2e8f0;
  --text-muted: #94a3b8;
  --white: #ffffff;
  --login-bg: #f1f5f9;
  --input-border: #cbd5e1;
  --input-focus: #f59e0b;
  --shadow: 0 4px 24px rgba(0,0,0,0.18);
  --page-bg: #f1f5f9;
  --left-surface: var(--dark-bg);
  --left-surface-2: var(--dark-card);
  --left-surface-3: var(--dark-card2);
  --left-border: var(--border-color);
  --left-text: var(--text-light);
  --left-muted: var(--text-muted);
  --right-surface: #ffffff;
  --right-panel-bg: var(--login-bg);
  --right-text: #0f172a;
  --right-muted: #64748b;
  --input-bg: #f8fafc;
  --divider-bg: #e2e8f0;
  --theme-btn-bg: rgba(255,255,255,0.08);
  --theme-btn-border: rgba(255,255,255,0.14);
  --theme-btn-text: var(--white);
}

body[data-theme="light"] {
  --page-bg: #f8fafc;
  --left-surface: #f6efe4;
  --left-surface-2: rgba(255,255,255,0.78);
  --left-surface-3: rgba(255,255,255,0.92);
  --left-border: rgba(34, 58, 115, 0.12);
  --left-text: #16335d;
  --left-muted: #64748b;
  --right-surface: #ffffff;
  --right-panel-bg: linear-gradient(180deg, #fffdf9 0%, #f4eee5 100%);
  --right-text: #0f172a;
  --right-muted: #64748b;
  --input-bg: #ffffff;
  --divider-bg: #dbe4ee;
  --theme-btn-bg: rgba(255,255,255,0.72);
  --theme-btn-border: rgba(34, 58, 115, 0.14);
  --theme-btn-text: #18345f;
}

body[data-theme="dark"] {
  --page-bg: #0b1422;
  --left-surface: var(--dark-bg);
  --left-surface-2: rgba(15,31,61,0.85);
  --left-surface-3: rgba(22,32,64,0.92);
  --left-border: var(--border-color);
  --left-text: var(--text-light);
  --left-muted: var(--text-muted);
  --right-surface: #0f1f3d;
  --right-panel-bg: linear-gradient(180deg, #101b2f 0%, #0d1729 100%);
  --right-text: #e2e8f0;
  --right-muted: #94a3b8;
  --input-bg: #16233f;
  --divider-bg: #243755;
  --theme-btn-bg: rgba(255,255,255,0.08);
  --theme-btn-border: rgba(255,255,255,0.14);
  --theme-btn-text: var(--white);
  --shadow: 0 8px 40px rgba(0,0,0,0.35);
}

html, body {
  height: 100%;
  font-family: 'Inter', sans-serif;
  background: var(--page-bg);
  overflow-x: hidden;
}

/* =============================================
   LAYOUT
   ============================================= */
.page-wrapper {
  display: flex;
  min-height: 100vh;
  width: 100%;
}

/* =============================================
   LEFT PANEL
   ============================================= */
.left-panel {
  flex: 1 1 0;
  min-width: 0;
  background: var(--left-surface);
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;  
  background-size: cover;
  background-position: center;
}

/* Hero Background */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 200px;
  height: 200px;
  opacity: 0.55;
}

.hero-bg-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(10,22,40,0.55) 0%,
    rgba(10,22,40,0.82) 38%,
    rgba(10,22,40,0.98) 65%,
    rgba(10,22,40,1) 100%
  );
  z-index: 1;
}

body[data-theme="light"] .hero-overlay {
  background: linear-gradient(
    to bottom,
    rgba(246,239,228,0.26) 0%,
    rgba(246,239,228,0.62) 38%,
    rgba(246,239,228,0.86) 65%,
    rgba(246,239,228,0.98) 100%
  );
}

/* Top Nav */
.top-nav {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 28px 14px 28px;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 13px;
}

.logo-icon {
  width: 48px;
  height: 48px;
  border: 2px solid var(--primary);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(245,158,11,0.08);
  position: relative;
}

.logo-icon svg {
  width: 30px;
  height: 30px;
}

.logo-text h1 {
  font-family: 'Poppins', sans-serif;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--left-text);
  letter-spacing: 0.5px;
  line-height: 1.1;
}

.logo-text h1 span {
  color: var(--primary);
}

.logo-text p {
  font-size: 0.72rem;
  color: var(--left-muted);
  font-weight: 400;
  margin-top: 1px;
}

/* ── Islamic Quotes Slider ── */
.quran-slider {
  background: rgba(10, 20, 42, 0.82);
  border: 1px solid var(--left-border);
  border-radius: 14px;
  padding: 12px 16px 10px 16px;
  max-width: 330px;
  min-width: 260px;
  overflow: hidden;
  position: relative;
  user-select: none;
}

body[data-theme="light"] .quran-slider {
  background: rgba(255, 255, 255, 0.74);
}

.quran-slides-wrap {
  position: relative;
  min-height: 62px;
}

.quran-slide {
  display: none;
  align-items: flex-start;
  gap: 11px;
  animation: qFadeIn 0.45s ease;
}

.quran-slide.active {
  display: flex;
}

@keyframes qFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.quran-arabic {
  font-size: 1.45rem;
  color: var(--primary);
  font-weight: 700;
  min-width: 36px;
  text-align: center;
  line-height: 1.2;
  padding-top: 2px;
  flex-shrink: 0;
}

.quran-text {
  font-size: 0.76rem;
  color: var(--left-text);
  font-style: italic;
  line-height: 1.55;
}

.quran-text span {
  display: block;
  color: var(--accent);
  font-style: normal;
  font-weight: 500;
  margin-top: 3px;
  font-size: 0.7rem;
}

/* Dots */
.quran-dots {
  display: flex;
  justify-content: center;
  gap: 5px;
  margin-top: 9px;
}

.quran-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--left-border);
  cursor: pointer;
  transition: background 0.25s, transform 0.25s;
  border: none;
  padding: 0;
  flex-shrink: 0;
}

.quran-dot.active {
  background: var(--primary);
  transform: scale(1.3);
}

.theme-toggle {
  border: 1px solid var(--theme-btn-border);
  background: var(--theme-btn-bg);
  color: var(--theme-btn-text);
  border-radius: 14px;
  padding: 10px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s ease;
}

.theme-toggle:hover {
  transform: translateY(-1px);
}

/* Content Area */
.left-content {
  position: relative;
  z-index: 10;
  padding: 0 28px 0 28px;
  margin-top: 28px;
}

.hero-title {
  font-family: 'Poppins', sans-serif;
  font-size: 2.35rem;
  font-weight: 800;
  color: var(--left-text);
  line-height: 1.15;
  margin-bottom: 4px;
}

.hero-subtitle {
  font-family: 'Poppins', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.2;
  margin-bottom: 40px;
}

.hero-desc {
  font-size: 0.88rem;
  color: var(--left-muted);
  max-width: 440px;
  line-height: 1.65;
  margin-bottom: 22px;
}

/* Feature Badges */
.feature-badges {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--left-surface-2);
  border: 1px solid var(--left-border);
  border-radius: 10px;
  padding: 9px 14px;
  color: var(--left-text);
  font-size: 0.78rem;
}

.badge-icon {
  width: 22px;
  height: 22px;
  color: var(--accent);
  flex-shrink: 0;
}

.badge strong {
  display: block;
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--left-text);
}

.badge span {
  font-size: 0.7rem;
  color: var(--left-muted);
}

/* Industries Section */
.industries-section {
  position: relative;
  z-index: 10;
  padding: 0 28px 20px 28px;
  margin-top: 8px;
}

.section-label {
  text-align: center;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 1px;
  margin-bottom: 16px;
  text-transform: uppercase;
}

.industries-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin-bottom: 8px;
}

.industry-card {
  background: var(--left-surface-2);
  border: 1px solid var(--left-border);
  border-radius: 10px;
  padding: 12px 6px 10px 6px;
  text-align: center;
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
  cursor: pointer;
}

.industry-card:hover {
  border-color: var(--accent);
  background: rgba(16,185,129,0.07);
  transform: translateY(-2px);
}

.industry-card .ic-icon {
  font-size: 1.5rem;
  margin-bottom: 6px;
  display: block;
}

.industry-card p {
  font-size: 0.67rem;
  color: var(--left-text);
  line-height: 1.4;
  font-weight: 500;
}

.industry-card small {
  font-size: 0.6rem;
  color: var(--left-muted);
  display: block;
}

/* Stats Bar */
.stats-bar {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-around;
  background: var(--left-surface-3);
  border: 1px solid var(--left-border);
  border-radius: 14px;
  margin: 0 28px 28px 28px;
  padding: 18px 10px;
}

.stat-item {
  text-align: center;
  display: flex;
  align-items: center;
  gap: 10px;
}

.stat-icon {
  font-size: 1.8rem;
  opacity: 0.85;
}

.stat-value {
  font-family: 'Poppins', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--left-text);
  line-height: 1;
}

.stat-label {
  font-size: 0.7rem;
  color: var(--left-muted);
  margin-top: 2px;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--left-border);
}

/* =============================================
   RIGHT PANEL - LOGIN
   ============================================= */
.right-panel {
  width: 625px;
  min-width: 380px;
  background: var(--right-panel-bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 32px 20px 18px 20px;
  position: relative;
}

.login-card {
  background: var(--right-surface);
  border-radius: 20px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.10);
  padding: 36px 32px 30px 32px;
  width: 100%;
  max-width: 585px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Logo */
.login-logo {
  margin-bottom: 18px;
}

.login-logo-icon {
  width: 64px;
  height: 64px;
  border: 2.5px solid var(--primary);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff8e1;
  margin: 0 auto;
}

.login-logo-icon svg {
  width: 38px;
  height: 38px;
}

.login-title {
  font-family: 'Poppins', sans-serif;
  font-size: 1.32rem;
  font-weight: 700;
  color: var(--right-text);
  text-align: center;
  margin-bottom: 24px;
  margin-top: 14px;
}

.login-title span {
  color: var(--primary);
}

.login-subtitle {
  font-size: 0.82rem;
  color: var(--right-muted);
  text-align: center;
  margin-bottom: 26px;
}

/* Form */
.login-form {
  width: 324px;
}

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

.form-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--right-text) 88%, transparent);
  margin-bottom: 6px;
}

.input-wrap {
  position: relative;
}

.input-icon {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--right-muted);
  width: 18px;
  height: 18px;
}

.form-input {
  width: 100%;
  border: 1.5px solid var(--input-border);
  border-radius: 10px;
  padding: 11px 40px 11px 40px;
  font-size: 0.88rem;
  color: var(--right-text);
  background: var(--input-bg);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  font-family: 'Inter', sans-serif;
}

.form-input::placeholder {
  color: var(--right-muted);
}

.form-input:focus {
  border-color: var(--input-focus);
  box-shadow: 0 0 0 3px rgba(245,158,11,0.12);
  background: var(--right-surface);
}

.input-right-icon {
  position: absolute;
  right: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--right-muted);
  width: 18px;
  height: 18px;
  cursor: pointer;
  transition: color 0.2s;
}

.input-right-icon:hover {
  color: var(--right-text);
}

/* Remember / Forgot */
.form-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  margin-top: 2px;
}

.remember-label {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  color: var(--right-muted);
  cursor: pointer;
  user-select: none;
}

.remember-label input[type="checkbox"] {
  accent-color: var(--primary);
  width: 15px;
  height: 15px;
  cursor: pointer;
}

.forgot-link {
  font-size: 0.82rem;
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s;
}

.forgot-link:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

/* Login Button */
.btn-login {
  width: 100%;
  background: linear-gradient(90deg, #f59e0b 0%, #f97316 100%);
  color: #fff;
  border: none;
  border-radius: 12px;
  padding: 13px 0;
  font-size: 1rem;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  letter-spacing: 0.2px;
  box-shadow: 0 4px 18px rgba(245,158,11,0.25);
  transition: transform 0.15s, box-shadow 0.15s, background 0.2s;
  margin-bottom: 18px;
}

.btn-login:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 28px rgba(245,158,11,0.35);
}

.btn-login:active {
  transform: translateY(0);
}

/* OR Divider */
.divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--divider-bg);
}

.divider span {
  font-size: 0.78rem;
  color: var(--right-muted);
}

/* Google Button */
.btn-google {
  width: 100%;
  background: var(--right-surface);
  border: 1.5px solid var(--divider-bg);
  border-radius: 12px;
  padding: 11px 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--right-text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-family: 'Inter', sans-serif;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

.btn-google:hover {
  background: var(--input-bg);
  border-color: var(--input-border);
  box-shadow: 0 3px 10px rgba(0,0,0,0.08);
}

body[data-theme="dark"] .login-card {
  box-shadow: 0 10px 40px rgba(0,0,0,0.32);
}

body[data-theme="dark"] .forgot-link,
body[data-theme="dark"] .help-item a {
  color: #fbbf24;
}

body[data-theme="dark"] .forgot-link:hover,
body[data-theme="dark"] .help-item a:hover {
  color: #f59e0b;
}

.google-icon {
  width: 20px;
  height: 20px;
}

/* Help Links */
.login-help {
  display: flex;
  justify-content: space-between;
  max-width: 370px;
  margin-top: 18px;
}

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

.help-item p {
  font-size: 0.75rem;
  color: var(--right-muted);
  margin-bottom: 2px;
}

.help-item a {
  font-size: 0.8rem;
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s;
}

.help-item a:hover {
  text-decoration: underline;
  color: var(--primary-dark);
}

/* Footer */
.right-footer {
  margin-top: 16px;
  font-size: 0.72rem;
  color: var(--right-muted);
  text-align: center;
  display: flex;
  align-items: center;
  gap: 5px;
}

.right-footer svg {
  width: 14px;
  height: 14px;
  color: var(--right-muted);
}

/* =============================================
   HERO IMAGES (CSS background approach)
   ============================================= */
.hero-images {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 220px;
  display: block;
  overflow: hidden;
  z-index: 0;
  background: transparent;
}

.hero-img-slot {
  display: none;
}

/* Industry icon colors */
.ic-healthcare { color: #34d399; }
.ic-manufacturing { color: #f59e0b; }
.ic-agriculture { color: #22c55e; }
.ic-trading { color: #60a5fa; }
.ic-import { color: #a78bfa; }
.ic-supply { color: #38bdf8; }
.ic-retail { color: #fb923c; }
.ic-wholesale { color: #facc15; }
.ic-service { color: #c084fc; }
.ic-courier { color: #f87171; }
.ic-ecommerce { color: #34d399; }
.ic-hr { color: #818cf8; }

/* =============================================
   ANIMATIONS
   ============================================= */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.animate-1 { animation: fadeInUp 0.6s ease both; }
.animate-2 { animation: fadeInUp 0.6s ease 0.1s both; }
.animate-3 { animation: fadeInUp 0.6s ease 0.2s both; }
.animate-4 { animation: fadeInUp 0.6s ease 0.3s both; }
.animate-5 { animation: fadeInUp 0.6s ease 0.4s both; }
.animate-6 { animation: fadeInUp 0.6s ease 0.5s both; }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1100px) {
  .hero-title { font-size: 1.9rem; }
  .hero-subtitle { font-size: 1.6rem; }
  .industries-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 860px) {
  .page-wrapper { flex-direction: column; }
  .right-panel { width: 100%; min-width: unset; }
  .industries-grid { grid-template-columns: repeat(3, 1fr); }
  .stats-bar { flex-wrap: wrap; gap: 14px; }
  .stat-divider { display: none; }
}

@media (max-width: 520px) {
  .industries-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-title { font-size: 1.5rem; }
  .hero-subtitle { font-size: 1.3rem; }
  .feature-badges { flex-direction: column; }
  .quran-slider { display: none; }
  .login-card { padding: 24px 16px 20px 16px; }
}
