/* ====== Root Theme Variables ====== */
:root {
  --primary-color: #d8deec;                 /* Bluish White base background (#D8DEEC) */
  --accent-blue: #2563eb;                   /* Professional strong blue accent */
  --gradient-blue: linear-gradient(135deg, #60a5fa 0%, #2563eb 100%);
  --glass-bg: rgba(235, 242, 255, 0.77);   /* Light blue glass overlay */
  --text-color: #18335d;                    /* Dark blue-gray for text */
  --text-muted: #6b7a93;                    /* Muted blue-gray text */
  --border-color: rgba(38, 99, 235, 0.13); /* Light blue border */
  --card-bg: #f3f7fa;                       /* Soft white-blue for cards and modals */
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --shadow-lg: 0 12px 36px rgba(38, 99, 235, 0.12);
  --shadow-md: 0 6px 24px rgba(38, 99, 235, 0.08);
  --transition-main: 0.35s cubic-bezier(.55,.06,.68,.19);
  --max-content-width: 1140px;
}

/* ====== Global Styles ====== */
html {
  box-sizing: border-box;
  font-size: 17px;
  scroll-behavior: smooth;
  scroll-padding-top: 80px; /* adjusts anchor jumps below fixed navbar */
}

*, *::before, *::after {
  box-sizing: inherit;
}

body {
  font-family: 'Poppins', 'Segoe UI', Arial, sans-serif;
  color: var(--text-color);
  background: var(--primary-color);
  margin: 0;
  min-height: 100vh;
  scroll-behavior: smooth;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.62;
  -webkit-text-size-adjust: 100%;
}

/* Link Styles */
a {
  color: var(--accent-blue);
  text-decoration: none;
  transition: color var(--transition-main);
}
a:hover,
a:focus {
  color: #7dd3fc;
  outline: none;
  text-decoration: underline;
}

/* ====== Navbar ====== */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 3vw;
  position: fixed;
  left: 0; top: 0; width: 100%;
  background: var(--glass-bg);
  backdrop-filter: blur(15px);
  border-bottom: 1.5px solid var(--border-color);
  z-index: 9999;
  box-shadow: var(--shadow-md);
}

.logo {
  height: 96px;
  width: auto;
  object-fit: contain;
  border-radius: var(--radius-sm);
  box-shadow: 0 3px 10px rgba(14, 165, 233, 0.12);
  background: transparent;
  transition: transform 0.3s ease;
}
.logo:hover,
.logo:focus {
  transform: scale(1.05);
}

/* Nav Links */
.nav-links {
  display: flex;
  gap: 2.8rem;
  padding: 0;
  margin: 0;
  list-style: none;
}
.nav-links li a {
  position: relative;
  font-weight: 600;
  font-size: 1.1rem;
  padding: 0.4rem 0;
  letter-spacing: 0.5px;
  transition: color var(--transition-main);
  white-space: nowrap;
}
.nav-links li a::after {
  content: '';
  position: absolute;
  left: 0; bottom: -5px;
  height: 3px;
  width: 0;
  border-radius: 3px;
  background: var(--accent-blue);
  transition: width var(--transition-main);
  will-change: width;
}
.nav-links li a:hover::after,
.nav-links li a:focus::after {
  width: 100%;
}

/* ====== Main Sections ====== */
.section {
  max-width: var(--max-content-width);
  margin: 0 auto;
  padding: 7rem 2.5vw 5rem 2.5vw;
  background: transparent;
}
.home-section {
  text-align: center;
  padding-top: 9rem;
  user-select: none;
}

/* ====== Header Image Styling ====== */
.header-img {
  width: 90vw;                    /* Responsive width */
  max-width: 650px;               /* Max for desktops */
  aspect-ratio: 1 / 1;            /* Square container */
  min-width: 280px;
  min-height: 280px;
  object-fit: contain;            /* Show entire image */
  object-position: center;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  background: #e3edfc;
  border: 3px solid var(--border-color);
  display: block;
  margin: 1rem auto 2.8rem auto;
  transition: box-shadow 0.35s ease;
}
.header-img:hover,
.header-img:focus {
  box-shadow: 0 16px 48px rgba(38, 99, 235, 0.22);
  outline-offset: 4px;
  outline: 2px solid var(--accent-blue);
}

/* ====== Headings & Text ====== */
.main-title {
  font-size: 3.6rem;
  margin: 2.4rem 0 0.65rem 0;
  font-weight: 900;
  background: var(--gradient-blue);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 1.7px;
  user-select: text;
  transition: filter 0.3s ease;
}
.main-title:hover,
.main-title:focus {
  filter: drop-shadow(0 0 6px rgba(14, 165, 233, 0.5));
  cursor: default;
}

.subtitle {
  font-size: 1.3rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-bottom: 2.8rem;
  letter-spacing: 0.7px;
}

h1, h2, h3, h4 {
  color: var(--text-color);
  font-weight: 700;
}

/* ====== Section Titles for consistency ====== */
.section-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1.8rem;
  color: var(--accent-blue);
  text-align: center;
  user-select: none;
  letter-spacing: 1px;
}

/* ====== Blog Cards ====== */
.blog-container {
  display: flex;
  flex-wrap: wrap;
  gap: 2.6rem;
  justify-content: center;
  margin-top: 3rem;
}

.blog-card {
  flex: 1 1 320px;
  background: var(--card-bg);
  padding: 1.8rem 1.4rem;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: box-shadow var(--transition-main), transform var(--transition-main);
  border: 1.7px solid var(--border-color);
  position: relative;
  min-width: 280px;
  max-width: 420px;
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.05);
  user-select: none;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}
.blog-card:hover,
.blog-card:focus {
  transform: translateY(-6px) scale(1.04);
  box-shadow: 0 20px 36px rgba(38, 99, 235, 0.26);
  border-color: var(--accent-blue);
  outline: none;
}
.blog-card h3 {
  margin-top: 0;
  color: var(--accent-blue);
  font-size: 1.32rem;
  font-weight: 700;
  margin-bottom: 0.7rem;
}
.blog-card p {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 0;
  flex-grow: 1;
  line-height: 1.5;
}

/* ====== Blog Expand Modal ====== */
.blog-expand {
  position: fixed;
  inset: 0;
  background: rgba(38, 57, 112, 0.95);
  width: 100vw;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2100;
  padding: 2vw;
  backdrop-filter: blur(6px);
}

.blog-content {
  background: var(--card-bg);
  padding: 2.5rem 2.2rem;
  border-radius: var(--radius-lg);
  max-width: 710px;
  width: 100%;
  box-shadow: var(--shadow-lg);
  user-select: text;
}
.hidden {
  display: none !important;
}

/* ====== Product Cards ====== */
.product-scroll {
  display: flex;
  gap: 1.4rem;
  overflow-x: auto;
  padding: 1.3rem 0.4rem;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: var(--accent-blue) var(--card-bg);
  user-select: none;
}
.product-scroll::-webkit-scrollbar {
  height: 8px;
  background: var(--card-bg);
}
.product-scroll::-webkit-scrollbar-thumb {
  background: var(--accent-blue);
  border-radius: 8px;
  transition: background 0.3s ease;
}
.product-scroll::-webkit-scrollbar-thumb:hover {
  background: #1e40af;
}

.product-card {
  flex: 0 0 320px;
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 2.4rem 1.8rem;
  margin-bottom: 0.2rem;
  text-align: center;
  font-weight: 600;
  border: 1.7px solid var(--border-color);
  scroll-snap-align: start;
  transition:
    background var(--transition-main),
    transform var(--transition-main),
    border-color var(--transition-main),
    box-shadow var(--transition-main);
  min-width: 230px;
  box-shadow: 0 3px 14px rgba(38, 99, 235, 0.11);
  user-select: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.product-card:hover,
.product-card:focus {
  background: rgba(38, 99, 235, 0.16);
  transform: scale(1.045);
  border-color: var(--accent-blue);
  box-shadow: 0 14px 44px rgba(38, 99, 235, 0.28);
  outline-offset: 3px;
  outline: 2px solid var(--accent-blue);
  cursor: pointer;
}
.product-card span {
  display: block;
  margin-top: 0.75rem;
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* ====== Story & About Text ====== */
#story p, #about p {
  font-size: 1.15rem;
  line-height: 1.9;
  max-width: 920px;
  margin: 1.4rem auto;
  color: #415680;
  user-select: text;
}

/* ====== Responsive Enhancements ====== */
@media (max-width: 1100px) {
  .section {
    max-width: 96vw;
    padding-right: 1.4vw;
    padding-left: 1.4vw;
  }
  .main-title {
    font-size: 2.6rem;
  }
  .header-img {
    max-width: 98vw;
  }
}

@media (max-width: 768px) {
  .navbar {
    padding: 0.85rem 4vw;
    flex-direction: column;
    gap: 0.8rem;
    align-items: flex-start;
    box-shadow: 0 2px 14px rgba(38, 99, 235, 0.16);
  }
  .nav-links {
    gap: 1.3rem;
    font-size: 1rem;
  }
  .main-title {
    font-size: 1.7rem;
  }
  .section {
    padding: 6rem 1.5vw 3.8rem 1.5vw;
  }
  .header-img {
    max-width: 96vw;
    min-height: 140px;
  }
  .blog-container {
    flex-direction: column;
    gap: 1.45rem;
  }
  .product-card {
    flex: 1 1 85vw;
    min-width: 200px;
  }
}

/* ====== Utility Classes ====== */
.text-center {
  text-align: center;
}
.mt-0 {
  margin-top: 0 !important;
}
.pt-2 {
  padding-top: 1.2rem !important;
}
.mb-0 {
  margin-bottom: 0 !important;
}
.rounded {
  border-radius: var(--radius-md) !important;
}
.shadow-lg {
  box-shadow: var(--shadow-lg) !important;
}
.shadow-md {
  box-shadow: var(--shadow-md) !important;
}
