/* ============================================================
   PORTFOLIO — style.css
   Dark + Light Theme
   ============================================================ */

html {
  scroll-behavior: smooth;
}

/* ========== DARK THEME (Default) ========== */
:root {
  --bg-body: #000000;
  --bg-section: #000000;
  --bg-card: #111111;
  --bg-input: #1a1a1a;
  --bg-input-focus: #1a1a1a;
  --bg-nav: rgba(0, 0, 0, 0.6);
  --bg-mobile-menu: #0a0a0a;
  --bg-dropdown: #0a0a0b;
  --bg-slider: #000000;
  --btn-bg: #ffffff;
  --btn-txt: #000000;

  --text-primary: #ffffff;
  --text-muted: #9ca3af;
  --text-subtle: #6b7280;
  --text-nav: #9ca3af;

  --border-color: rgba(255, 255, 255, 0.1);
  --border-section: rgba(255, 255, 255, 0.05);

  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.4);
  --stroke-glow-color: rgba(255, 255, 255, 0.55);
  --stroke-shadow: rgba(255, 255, 255, 0.1);

  --hero-glow-1: rgba(59, 130, 246, 0.1);
  --hero-glow-2: rgba(37, 99, 235, 0.05);
  --hero-border: rgba(255, 255, 255, 0.1);
  --hero-overlay: rgba(0, 0, 0, 0.4);

  --slider-fade: rgba(0, 0, 0, 0.9);

  --filter-btn-bg: #1a1a1a;
  --filter-btn-text: #d1d5db;
  --filter-btn-hover: #282828;

  --toggle-border: rgba(255, 255, 255, 0.15);
  --toggle-hover: rgba(37, 99, 235, 0.15);

  /* Glass card variables */
  --glass-bg: rgba(255, 255, 255, 0.055);
  --glass-bg-2: rgba(255, 255, 255, 0.015);
  --glass-border: rgba(255, 255, 255, 0.11);
  --glass-inset-top: rgba(255, 255, 255, 0.16);
  --glass-inset-bottom: rgba(0, 0, 0, 0.55);
  --glass-shadow: rgba(0, 0, 0, 0.5);

  /* Section card bg */
  --card-bg-from: rgba(22, 22, 40, 0.96);
  --card-bg-to: rgba(11, 11, 22, 0.98);

  /* Grid lines */
  --grid-color: #808080;

  /* HFC floating cards */
  --hfc-bg: rgba(255, 255, 255, 0.06);
  --hfc-border: rgba(255, 255, 255, 0.12);
}

/* ========== LIGHT THEME ========== */
:root.light {
  --bg-body: #f5f7fa;
  --bg-section: #f5f7fa;
  --bg-card: #ffffff;
  --bg-input: #e8edf3;
  --bg-input-focus: #ffffff;
  --bg-nav: rgba(240, 244, 248, 0.85);
  --bg-mobile-menu: #ffffff;
  --bg-dropdown: #ffffff;
  --bg-slider: #f0f4f8;
  --btn-bg: #0f172a;
  --btn-txt: #ffffff;

  --text-primary: #0f172a;
  --text-muted: #475569;
  --text-subtle: #64748b;
  --text-nav: #475569;

  --border-color: rgba(0, 0, 0, 0.08);
  --border-section: rgba(0, 0, 0, 0.05);

  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.08);
  --stroke-glow-color: rgba(0, 0, 0, 0.4);
  --stroke-shadow: rgba(0, 0, 0, 0.08);

  --hero-glow-1: rgba(4, 141, 240, 0.08);
  --hero-glow-2: rgba(39, 54, 84, 0.05);
  --hero-border: rgba(0, 0, 0, 0.08);
  --hero-overlay: rgba(240, 244, 248, 0.3);

  --slider-fade: rgba(240, 244, 248, 0.9);

  --filter-btn-bg: #e2e8f0;
  --filter-btn-text: #334155;
  --filter-btn-hover: #cbd5e1;

  --toggle-border: rgba(0, 0, 0, 0.12);
  --toggle-hover: rgba(4, 141, 240, 0.08);

  /* Glass card variables */
  --glass-bg: rgba(255, 255, 255, 0.75);
  --glass-bg-2: rgba(255, 255, 255, 0.55);
  --glass-border: rgba(0, 0, 0, 0.08);
  --glass-inset-top: rgba(255, 255, 255, 0.9);
  --glass-inset-bottom: rgba(0, 0, 0, 0.05);
  --glass-shadow: rgba(0, 0, 0, 0.08);

  /* Section card bg */
  --card-bg-from: rgba(255, 255, 255, 0.95);
  --card-bg-to: rgba(240, 244, 248, 0.98);

  /* Grid lines */
  --grid-color: #94a3b8;

  /* HFC floating cards */
  --hfc-bg: rgba(255, 255, 255, 0.85);
  --hfc-border: rgba(0, 0, 0, 0.1);
}

/* ========== BASE ========== */
body {
  font-family: "Lora", serif;
  background: var(--bg-body);
  color: var(--text-primary);
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* ========== LIGHT MODE — text overrides ========== */
:root.light .text-white {
  color: var(--text-primary) !important;
}
:root.light .text-slate-400 {
  color: #475569 !important;
}
:root.light .text-slate-500 {
  color: #64748b !important;
}
:root.light .text-slate-300 {
  color: #334155 !important;
}
:root.light .text-slate-700 {
  color: #94a3b8 !important;
}
:root.light .text-gray-400 {
  color: var(--text-muted) !important;
}
:root.light .text-gray-300 {
  color: var(--text-muted) !important;
}
:root.light .text-gray-500 {
  color: var(--text-subtle) !important;
}

/* Nav links — light mode এ dark হবে কিন্তু gradient/colored text সাদা থাকবে */
:root.light #header a.text-gray-400,
:root.light #header nav a {
  color: #334155 !important;
}
:root.light #header nav a:hover {
  color: #0f172a !important;
}

/* Colored/gradient বাটনের ভেতরের text সবসময় সাদা */
:root.light a[style*="background:#048DF0"],
:root.light button[style*="background:#048DF0"],
:root.light a[style*="background: #048DF0"],
:root.light a[style*="background:linear-gradient"],
:root.light button[style*="background:linear-gradient"] {
  color: #ffffff !important;
}
/* Gradient icon boxes এর ভেতরের text/icon সাদা */
:root.light [style*="background: linear-gradient(135deg"] .text-white,
:root.light [style*="background:linear-gradient(135deg"] .text-white {
  color: #ffffff !important;
}

/* ========== LIGHT MODE — smooth shadows ========== */
/* সব section/card এর heavy black shadow হালকা করা */
:root.light section {
  box-shadow: none !important;
}

/* Glass cards — light mode এ soft shadow */
:root.light [style*="0 30px 70px rgba(0,0,0"],
:root.light [style*="0 24px 60px rgba(0,0,0"],
:root.light [style*="0 28px 60px rgba(0,0,0"] {
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 -1px 0 rgba(0, 0, 0, 0.04) inset, 0 4px 24px rgba(0, 0, 0, 0.07),
    0 1px 4px rgba(0, 0, 0, 0.05) !important;
}

/* Service cards — dark bg light mode এ white */
:root.light [style*="rgba(22,22,40"],
:root.light [style*="rgba(11,11,22"] {
  background: rgba(255, 255, 255, 0.95) !important;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.07), 0 1px 4px rgba(0, 0, 0, 0.05) !important;
  border-color: rgba(0, 0, 0, 0.08) !important;
}

/* HFC floating cards */
:root.light .hfc-card {
  background: rgba(255, 255, 255, 0.92) !important;
  border-color: rgba(0, 0, 0, 0.09) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.09),
    0 1px 0 rgba(255, 255, 255, 1) inset !important;
}

/* Solid glass cards */
:root.light [style*="rgba(255,255,255,0.055)"],
:root.light [style*="rgba(255,255,255,0.06)"] {
  background: rgba(255, 255, 255, 0.92) !important;
  border-color: rgba(0, 0, 0, 0.08) !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.07),
    0 1px 0 rgba(255, 255, 255, 1) inset !important;
}

/* Nav bar */
:root.light #header > div > div {
  background: rgba(255, 255, 255, 0.92) !important;
  border-color: rgba(0, 0, 0, 0.09) !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08),
    0 1px 0 rgba(255, 255, 255, 0.9) inset !important;
  backdrop-filter: blur(20px) !important;
}

/* Buttons — #048DF0 সলিড বাটনের shadow smooth */
:root.light a[style*="background:#048DF0"],
:root.light button[style*="background:#048DF0"] {
  box-shadow: 0 2px 12px rgba(4, 141, 240, 0.35),
    0 1px 0 rgba(255, 255, 255, 0.3) inset !important;
}

/* Gradient icon squares */
:root.light [style*="background: linear-gradient(135deg, #048DF0"],
:root.light [style*="background:linear-gradient(135deg,#048DF0"] {
  box-shadow: 0 4px 12px rgba(4, 141, 240, 0.25) !important;
}

/* Testimonial/process dark cards */
:root.light [style*="rgba(20,20,36"],
:root.light [style*="rgba(22,22,40"] {
  background: #ffffff !important;
  border-color: rgba(0, 0, 0, 0.07) !important;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.07) !important;
}

/* Stats mini cards */
:root.light [style*="0 10px 28px rgba(0,0,0"] {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07) !important;
  border-color: rgba(0, 0, 0, 0.08) !important;
}

/* CTA card */
:root.light [style*="0 40px 100px rgba(0,0,0"] {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08) !important;
  background: rgba(255, 255, 255, 0.95) !important;
}

/* Service card gradient bg — text fix */
:root.light .service-card .text-white,
:root.light .process-card .text-white {
  color: #0f172a !important;
}
:root.light .service-card .text-slate-500,
:root.light .process-card .text-slate-500 {
  color: #64748b !important;
}
:root.light .service-card .text-slate-400,
:root.light .process-card .text-slate-400 {
  color: #475569 !important;
}

/* Testimonial cards text */
:root.light .text-slate-400 {
  color: #475569 !important;
}
:root.light .text-slate-500 {
  color: #64748b !important;
}

/* ========== LIGHT MODE — background overrides ========== */
:root.light section,
:root.light .bg-\[var\(--bg-body\)\] {
  background-color: var(--bg-body) !important;
}

/* Glass cards in light mode */
:root.light [style*="rgba(255,255,255,0.055)"],
:root.light [style*="rgba(255,255,255,0.06)"] {
  background: var(--glass-bg) !important;
}

/* Dark section cards in light mode */
:root.light [style*="rgba(22,22,40"],
:root.light [style*="rgba(11,11,22"] {
  background: var(--card-bg-from) !important;
}

/* ========== LIGHT MODE — border overrides ========== */
:root.light .border-white\/10 {
  border-color: var(--border-color) !important;
}
:root.light .border-white\/5 {
  border-color: var(--border-section) !important;
}

/* ========== LIGHT MODE — nav ========== */
:root.light #header > div > div {
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.9),
    rgba(240, 244, 248, 0.95)
  ) !important;
  border-color: rgba(0, 0, 0, 0.08) !important;
}
:root.light #mobileMenu {
  background-color: #ffffff !important;
  border-color: rgba(0, 0, 0, 0.08) !important;
}
:root.light #mobileMenu a {
  color: #334155 !important;
}

/* ========== LIGHT MODE — HFC cards ========== */
:root.light .hfc-card {
  background: rgba(255, 255, 255, 0.85) !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
}
:root.light .hfc-card span,
:root.light .hfc-card div {
  color: var(--text-primary);
}

/* ========== LIGHT MODE — logo marquee ========== */
:root.light .logo-marquee-section {
  background-color: var(--bg-body) !important;
  border-color: var(--border-color) !important;
}
:root.light .logo-pill {
  background: rgba(255, 255, 255, 0.8) !important;
  border-color: rgba(0, 0, 0, 0.08) !important;
  color: rgba(15, 23, 42, 0.7) !important;
}

/* ========== THEME TOGGLE BUTTON ========== */
#themeToggle {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #9ca3af;
  flex-shrink: 0;
}
#themeToggle:hover {
  background: rgba(4, 141, 240, 0.12);
  border-color: rgba(4, 141, 240, 0.3);
  color: #048df0;
  transform: scale(1.05);
}
:root.light #themeToggle {
  background: rgba(0, 0, 0, 0.05);
  border-color: rgba(0, 0, 0, 0.1);
  color: #475569;
}
:root.light #themeToggle:hover {
  background: rgba(4, 141, 240, 0.08);
  border-color: rgba(4, 141, 240, 0.25);
  color: #048df0;
}

/* #048DF0 বাটনের text সবসময় সাদা — light/dark দুই mode এ */
a[style*="background:#048DF0"],
button[style*="background:#048DF0"] {
  color: #ffffff !important;
}
a[style*="background:#048DF0"] *,
button[style*="background:#048DF0"] * {
  color: #ffffff !important;
}

.hero-headline {
  color: #ffffff;
}
.hero-title-main {
  color: inherit;
}

/* Badge dark */
.hero-badge {
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
}
.hero-badge-text {
  color: #c7c9ff;
}

/* Ghost button dark */
.hero-ghost-btn {
  border: 2px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  background: transparent;
}
.hero-ghost-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

/* Light mode hero overrides */
:root.light .hero-headline {
  color: #0f172a;
}
:root.light .hero-title-main {
  color: #0f172a !important;
}

:root.light .hero-badge {
  border: 1px solid rgba(4, 141, 240, 0.2);
  background: rgba(4, 141, 240, 0.06);
}
:root.light .hero-badge-text {
  color: #334155;
}

:root.light .hero-ghost-btn {
  border: 2px solid rgba(4, 141, 240, 0.3);
  color: #0f172a;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(12px);
}
:root.light .hero-ghost-btn:hover {
  background: rgba(4, 141, 240, 0.06);
  border-color: rgba(4, 141, 240, 0.5);
}

/* Fix gradient text "For AI Startups" */
.hero-title-gradient {
  text-decoration: none !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  text-shadow: none !important;
  background-color: transparent !important;
  display: inline !important;
  filter: none !important;
}
/* Light mode এ gradient text এর নীল glow সরানো */
:root.light .hero-title-gradient {
  text-shadow: none !important;
  filter: none !important;
  -webkit-filter: none !important;
}

/* Dark glow show/hide */
:root:not(.light) .hero-dark-glow {
  opacity: 0.35;
}
:root.light .hero-dark-glow {
  opacity: 0 !important;
}
:root.light .hero-light-glow {
  opacity: 1 !important;
}

:root.light body {
  background: linear-gradient(160deg, #f5f7fa 0%, #e8eef6 100%) !important;
  background-attachment: fixed !important;
}
:root.light section {
  background: transparent !important;
}
:root.light .bg-\[var\(--bg-body\)\] {
  background: transparent !important;
}

/* Light glow show */
:root.light .hero-light-glow {
  opacity: 1 !important;
}

.gradient-primary {
  background: linear-gradient(135deg, #2563eb, #7c3aed);
}
.gradient-cta {
  background: linear-gradient(135deg, #2563eb, #6d28d9);
}
.shadow-glow {
  box-shadow: 0 0 30px rgba(37, 99, 235, 0.3);
}
.shadow-card {
  box-shadow: var(--shadow-card);
}
.text-gradient {
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ========== SCROLL ANIMATIONS ========== */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ========== CARD HOVER ========== */
.card-hover {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card-hover:hover {
  transform: translateY(-8px);
}
.img-zoom img {
  transition: transform 0.5s ease;
}
.img-zoom:hover img {
  transform: scale(1.05);
}
.project-zoom img {
  transition: transform 0.5s ease;
}
.project-zoom:hover img {
  transform: scale(1.1);
}

/* ========== HERO SLIDE IN ANIMATION ========== */
@keyframes slideIn {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(0);
  }
}

/* ========== MARQUEE SLIDER ========== */
.stroke-glow {
  -webkit-text-stroke: 1.5px var(--stroke-glow-color);
  filter: drop-shadow(0 0 10px var(--stroke-shadow));
}

@keyframes marquee {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

.animate-marquee {
  animation: marquee 20s linear infinite !important;
  mask-image: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.1) 0%,
    white 30%,
    white 70%,
    rgba(0, 0, 0, 0.1) 100%
  );
  -webkit-mask-image: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.1) 0%,
    white 30%,
    white 70%,
    rgba(0, 0, 0, 0.1) 100%
  );
}

/* ========== BASE BACKGROUNDS ========== */
body,
section,
.bg-black,
#home {
  background-color: var(--bg-body);
}
#home {
  background: var(--bg-body) !important;
}
.bg-\[#111\] {
  background-color: var(--bg-card);
}
.bg-\[#1a1a1a\] {
  background-color: var(--bg-input);
}
section {
  background-color: var(--bg-section);
}

/* ========== TEXT COLORS ========== */
.text-white {
  color: var(--text-primary) !important;
}
.text-gray-400 {
  color: var(--text-muted) !important;
}
.text-gray-300 {
  color: var(--text-muted) !important;
}
.text-gray-500 {
  color: var(--text-subtle) !important;
}

/* ========== BORDERS ========== */
.border-white\/10 {
  border-color: var(--border-color) !important;
}
.border-white\/5 {
  border-color: var(--border-section) !important;
}

/* ========== NAV ========== */
#header .bg-black\/60 {
  background-color: var(--bg-nav) !important;
  border-color: var(--border-color) !important;
}
#header .text-gray-400 {
  color: var(--text-nav) !important;
}
#header .bg-\[#0a0a0b\] {
  background-color: var(--bg-dropdown) !important;
  border-color: var(--border-color) !important;
}
#mobileMenu {
  background-color: var(--bg-mobile-menu) !important;
  border-color: var(--border-color) !important;
}

/* ========== FILTER BUTTONS ========== */
.filter-btn {
  transition: all 0.3s ease;
}
.filter-btn.active {
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: #ffffff;
}

/* ========== MARQUEE FAST ========== */
@keyframes marquee-fast {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}
.animate-marquee-fast {
  display: flex;
  width: max-content;
  animation: marquee-fast 20s linear infinite;
}
.pause-scroll:hover {
  animation-play-state: paused;
}

/* ========== HFC FLOATING CARDS ========== */
.hfc-card {
  background: var(--hfc-bg);
  border: 1px solid var(--hfc-border);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition: background 0.3s ease, border-color 0.3s ease;
}

@keyframes hfc-float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}
.hfc {
  will-change: transform;
}

/* ========== LOGO MARQUEE SECTION ========== */
.logo-marquee-section {
  background-color: var(--bg-body);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  transition: background-color 0.3s ease;
}

/* Dark mode — logos সাদা */
:root:not(.light) .marquee-logo-img {
  filter: brightness(0) invert(1);
}

/* Light mode — original color */
:root.light .marquee-logo-img {
  filter: none;
}

@keyframes logo-marquee {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}
.animate-logo-marquee {
  animation: logo-marquee 28s linear infinite;
  display: flex;
  gap: 12px;
  width: max-content;
}
.animate-logo-marquee:hover {
  animation-play-state: paused;
}

/* ========== SERVICE BUTTON ========== */
.svc-btn:hover {
  filter: brightness(1.15);
  transform: scale(1.03);
}

/* ========== MISC ========== */
.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
