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

:root {
  --bs-primary: #ff9e18;
  --bs-primary-rgb: 249, 156, 36;
  --primary-color: #ff9e18;
  --secondary-color: #fcae3f;
  --accent-color: #0f172a;
  --dark-color: #111111;
  --light-color: #f8fafc;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --gradient-primary: linear-gradient(135deg, #ff9e18 0%, #fcae3f 100%);
  --glass-bg: rgba(255, 255, 255, 0.95);
  --glass-border: rgba(255, 255, 255, 0.2);
}

.text-primary {
    color: var(--primary-color) !important;
}
.bg-primary {
    background-color: var(--primary-color) !important;
}
.border-primary {
    border-color: var(--primary-color) !important;
}
.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}
.btn-outline-primary:hover {
    color: white;
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}
.btn-primary {
    color: white;
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}
.btn-primary:hover {
    color: white;
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--text-primary);
  background-color: var(--light-color);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden; /* Prevent horizontal scroll on mobile */
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  color: var(--dark-color);
}

/* Navbar */
.navbar-custom {
  background: var(--primary-color);
  border-bottom: none;
  box-shadow: 0 4px 15px rgba(255, 158, 24, 0.3);
  transition: all 0.3s ease;
  min-height: 76px;
  padding-top: 10px;
  padding-bottom: 10px;
  overflow: visible;
  z-index: 1030;
}

.navbar-custom .container {
  overflow: visible;
}

.navbar-brand {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  color: white !important;
  letter-spacing: -0.5px;
  padding: 0;
  line-height: 1;
  display: flex;
  align-items: center;
}

.navbar-brand img {
  display: block !important;
  height: 36px !important;
  width: auto !important;
  max-width: 130px !important;
  object-fit: contain;
  mix-blend-mode: multiply;
  flex-shrink: 0;
}

.nav-link {
  font-weight: 500;
  transition: color 0.25s ease;
}

/* =============================================
   ADMIN HIERARCHY (TREE VIEW)
   ============================================= */
.bg-soft-primary {
  background-color: rgba(var(--bs-primary-rgb), 0.1) !important;
}

.border-primary-subtle {
  border-color: rgba(var(--bs-primary-rgb), 0.2) !important;
}

tr.bg-light.border-start.border-primary.border-4 {
  background-color: #f8f9fa !important;
}

/* Tooltip & Labels for Hierarchy */
.badge.text-primary.bg-soft-primary {
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-weight: 700;
}

/* End of Custom Styles */

/* Custom nav links — animated underline on hover */
.nav-link-custom {
  position: relative;
  color: rgba(255, 255, 255, 0.82) !important;
  font-weight: 500;
  letter-spacing: 0.01em;
  padding-bottom: 4px !important;
}

.nav-link-custom::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  right: 50%;
  height: 2px;
  background: white;
  border-radius: 2px;
  transition: left 0.28s ease, right 0.28s ease, opacity 0.28s ease;
  opacity: 0;
}

.nav-link-custom:hover,
.nav-link-custom.active {
  color: white !important;
}

.nav-link-custom:hover::after,
.nav-link-custom.active::after {
  left: 8px;
  right: 8px;
  opacity: 1;
}

/* Contact Us CTA button in navbar */
.btn-nav-cta {
  color: #ff9e18;
  background: white;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}

.btn-nav-cta:hover {
  background: #fff3dd;
  color: #d47e00;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}

/* Mobile navbar expanded background */
@media (max-width: 991.98px) {
  .navbar-collapse.show {
    background: var(--primary-color);
    padding: 12px 0 16px;
    border-top: 1px solid rgba(255,255,255,0.15);
    margin-top: 8px;
  }
}

/* =============================================
   PAGE HERO BANNERS (interior pages)
   Compact dark header strip for sub-pages
   ============================================= */
.page-hero-banner {
  padding: 36px 0 32px;
  position: relative;
}

@media (max-width: 767.98px) {
  .page-hero-banner { padding: 28px 0 24px; }
  .page-hero-banner h1 { font-size: 1.6rem !important; }
}

/* =============================================
   PRODUCT DETAIL — Main image box
   ============================================= */
.product-main-img-box {
  background: #f8f9fa;
  height: clamp(240px, 36vw, 320px);
  overflow: hidden;
  transition: box-shadow 0.2s ease;
}

.product-main-img-box:hover {
  box-shadow: 0 8px 30px rgba(0,0,0,0.10) !important;
}

/* =============================================
   HERO BANNER CAROUSEL — Responsive Heights
   ============================================= */

.hero-slide {
  aspect-ratio: 1920 / 800;
  min-height: 400px; /* Safe minimum height for text content */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
  display: flex;
  align-items: center;
}

/* Hero title — fluid typography, no !important needed */
.hero-slide h1, .hero-slide h2 {
  font-size: clamp(1.4rem, 4vw, 2.8rem);
  line-height: 1.2;
}

.hero-slide .lead {
  font-size: clamp(0.85rem, 2vw, 1.1rem);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Tablet (768–991px) */
@media (max-width: 991.98px) {
  .hero-slide { min-height: auto; }
  .hero-slide .carousel-caption > div { max-width: 90% !important; }
  .hero-slide .btn { padding: 10px 22px; font-size: 0.9rem; }
}

/* Mobile (< 768px) */
@media (max-width: 767.98px) {
  .hero-slide { min-height: 250px; padding: 1rem 0; }
  .hero-slide .carousel-caption { padding: 1.5rem; }
  .hero-slide .btn { padding: 8px 18px; font-size: 0.85rem; }
  .navbar-collapse.show { padding: 20px 0; }
  /* Full-width primary action buttons on mobile */
  .btn-lg { min-height: 48px; }
  .hero-slide .btn-lg { width: 100%; }
}

/* Very small mobile (< 480px) */
@media (max-width: 479.98px) {
  .hero-slide { min-height: 310px; }
  .hero-slide .lead { display: none; }
}


/* Hero Section */
.hero-section {
  position: relative;
  background: var(--dark-color);
  color: white;
  padding: 120px 0;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(circle at top right, rgba(255, 158, 24, 0.15) 0%, transparent 60%),
              radial-gradient(circle at bottom left, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 24px;
  background: linear-gradient(to right, #fff, #94a3b8);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Buttons */
.btn-primary-custom {
  background: var(--gradient-primary);
  border: none;
  border-radius: 8px;
  padding: 12px 28px;
  font-weight: 600;
  color: white;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 14px 0 rgba(255, 158, 24, 0.39);
}

.btn-primary-custom:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px 0 rgba(255, 158, 24, 0.5);
  color: white;
}

/* Cards */
.tool-card {
  background: white;
  border-radius: 16px;
  border: 1px solid rgba(0,0,0,0.05);
  overflow: hidden;
  transition: all 0.3s ease;
  height: 100%;
  position: relative; /* Added to bound stretched-links correctly */
}

.tool-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Product card image container — aspect ratio instead of fixed height */
.tool-card-img {
  aspect-ratio: 4 / 3;
  object-fit: contain;
  object-position: center;
  width: 100%;
  background: #f8f9fa;
  padding: 8px;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  display: block;
}

/* Catalog card image wrapper — responsive aspect ratio */
.tool-card .card-img-wrap {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  flex-shrink: 0;
  background: #f8f9fa;
  position: relative;
}

.tool-card .card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  padding: 10px;
  display: block;
}

/* Touch-friendly View Specs button */
.btn-view-specs {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Universal image cover box — use on any <img> that must fill its container */
.img-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Ensures img parent containers don't let images overflow or distort */
.img-box {
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f3f4f6;
}

.badge-custom {
  background: rgba(255, 158, 24, 0.15);
  color: var(--primary-color);
  padding: 6px 12px;
  border-radius: 20px;
  font-weight: 500;
  font-size: 0.8rem;
}

/* Footer */
footer {
  background: var(--dark-color);
  color: #94a3b8;
  padding: 60px 0 20px;
}

.footer-heading {
  color: white;
  font-family: 'Outfit';
  font-weight: 600;
  margin-bottom: 20px;
}

.footer-link {
  color: #94a3b8;
  text-decoration: none;
  transition: color 0.2s;
  display: block;
  margin-bottom: 10px;
}

.footer-link:hover {
  color: white;
}

/* Utilities */
.section-padding {
  padding: 80px 0;
}

/* Animations */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-up {
  animation: fadeInUp 0.6s ease-out forwards;
}

/* =============================================
   BLOG CONTENT TYPOGRAPHY
   Styles applied to TinyMCE HTML output
   ============================================= */
.blog-content { font-size:1.08rem; line-height:1.85; color:#1e293b; }
.blog-content p { margin-bottom: 1.25rem; }
.blog-content h1,.blog-content h2,.blog-content h3,.blog-content h4 {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  margin-top: 2rem;
  margin-bottom: 1rem;
  color: #0f172a;
}
.blog-content h2 { font-size: 1.6rem; }
.blog-content h3 { font-size: 1.3rem; }
.blog-content strong { color: #0f172a; }
.blog-content a { color: #ff9e18; }
.blog-content ul,.blog-content ol { padding-left: 1.5rem; margin-bottom: 1.25rem; }
.blog-content li { margin-bottom: 0.4rem; }
.blog-content img { max-width:100%; height:auto; border-radius:12px; margin:1.5rem 0; display:block; }
.blog-content blockquote {
  border-left: 4px solid #ff9e18;
  background: #fff9f0;
  padding: 1rem 1.5rem;
  border-radius: 0 8px 8px 0;
  margin: 1.5rem 0;
  font-style: italic;
  color: #475569;
}
.blog-content table { width:100%; border-collapse:collapse; margin-bottom:1.25rem; }
.blog-content th,.blog-content td { border:1px solid #e2e8f0; padding:8px 12px; }
.blog-content th { background:#f8f9fa; font-weight:600; }
/* Strip TinyMCE citation superscripts */
.blog-content sup.superscript { display:none; }

/* Social Icons */
.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  transition: background 0.2s, transform 0.2s;
}
.social-icon:hover {
  background: #ff9e18;
  transform: translateY(-3px);
}