/* ==========================================================================
   SAAS ENGINEERING TECHNICAL SERVICES LTD - Core Stylesheet
   Industrial Engineering, Fabrication, Pipeline & Oilfield Solutions
   ========================================================================== */

:root {
  --primary: #0d2847;
  --primary-dark: #07172b;
  --primary-light: #1b497c;
  --accent: #d97706;
  --accent-hover: #b45309;
  --accent-glow: rgba(217, 119, 6, 0.2);
  --dark: #0f172a;
  --gray-900: #111827;
  --gray-800: #1f2937;
  --gray-700: #374151;
  --gray-600: #4b5563;
  --gray-500: #6b7280;
  --gray-400: #9ca3af;
  --gray-300: #d1d5db;
  --gray-200: #e5e7eb;
  --gray-100: #f3f4f6;
  --gray-50: #f8fafc;
  --white: #ffffff;
  
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-heading: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  width: 100%;
}

section[id], article[id], .division-card[id] {
  scroll-margin-top: 85px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--white);
  color: var(--gray-700);
  line-height: 1.65;
  overflow-x: clip;
  width: 100%;
  position: relative;
}

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

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

ul, ol {
  list-style: none;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  border: none;
  outline: none;
}

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--dark);
  font-weight: 700;
  line-height: 1.25;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.5rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.75rem); }
h4 { font-size: 1.2rem; }

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(217, 119, 6, 0.1);
  color: var(--accent);
  padding: 0.35rem 0.85rem;
  border-radius: 9999px;
  font-size: 0.825rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.85rem;
  border: 1px solid rgba(217, 119, 6, 0.25);
}

.section-tag svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.section-header {
  text-align: center;
  max-width: 780px;
  margin: 0 auto 3.5rem;
}

.section-header p {
  color: var(--gray-600);
  font-size: 1.1rem;
  margin-top: 0.75rem;
}

/* Top Utility Bar */
.top-bar {
  background-color: var(--primary-dark);
  color: var(--gray-300);
  font-size: 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.top-bar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.55rem 0;
  flex-wrap: wrap;
  gap: 1rem;
}

.top-bar-info {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  flex-wrap: wrap;
  min-width: 0;
}

.info-item {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  word-break: break-all;
  overflow-wrap: anywhere;
  min-width: 0;
}

.info-item svg {
  width: 15px;
  height: 15px;
  fill: var(--accent);
  flex-shrink: 0;
}

.top-bar-social {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.social-link {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--gray-300);
  transition: var(--transition);
}

.social-link svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.social-link:hover {
  background: var(--accent);
  color: var(--white);
}

/* Main Navigation */
.site-header {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  z-index: 1000;
  transition: var(--transition);
}

.site-header.scrolled {
  box-shadow: var(--shadow-md);
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.85rem 1.5rem;
  gap: 1.5rem;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-shrink: 0;
}

.brand-logo img {
  width: 52px;
  height: 52px;
  object-fit: contain;
  flex-shrink: 0;
}

.brand-text {
  display: flex;
  flex-direction: column;
  white-space: nowrap;
}

.brand-title {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  color: var(--primary);
  line-height: 1.15;
  white-space: nowrap;
}

.brand-sub {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--gray-500);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-shrink: 0;
}

@media (max-width: 1280px) and (min-width: 1141px) {
  .nav-container {
    gap: 1rem;
    padding: 0.75rem 1.25rem;
  }

  .nav-menu {
    gap: 0.85rem;
  }

  .nav-link {
    font-size: 0.85rem;
    padding: 0.35rem 0.15rem;
  }

  .brand-title {
    font-size: 1.05rem;
  }

  .brand-sub {
    font-size: 0.68rem;
  }

  .nav-cta .btn {
    padding: 0.5rem 0.85rem;
    font-size: 0.825rem;
  }
}

.nav-link {
  font-size: 0.925rem;
  font-weight: 500;
  color: var(--gray-700);
  padding: 0.4rem 0.25rem;
  position: relative;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  cursor: pointer;
}

.nav-link:hover, .nav-link.active {
  color: var(--primary);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 2px;
  background-color: var(--accent);
  transition: var(--transition);
}

.nav-link:hover::after, .nav-link.active::after {
  width: 100%;
}

/* Core Divisions Dropdown */
.nav-item-dropdown {
  position: relative;
  display: flex;
  align-items: center;
}

.dropdown-chevron {
  width: 14px;
  height: 14px;
  fill: currentColor;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.nav-dropdown-menu {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

@media (min-width: 1141px) {
  .nav-item-dropdown:hover .dropdown-chevron {
    transform: rotate(180deg);
  }

  .nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 320px;
    box-shadow: 0 12px 28px -4px rgba(13, 40, 71, 0.16), 0 0 0 1px rgba(13, 40, 71, 0.08);
    opacity: 0;
    visibility: hidden;
  }

  .nav-item-dropdown:hover .nav-dropdown-menu,
  .nav-item-dropdown:focus-within .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%);
  }
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-sm);
  color: var(--gray-700);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.dropdown-item:hover {
  background-color: var(--gray-50);
  color: var(--primary);
}

.dropdown-item:hover .dropdown-num {
  background-color: var(--primary);
  color: var(--white);
}

.dropdown-num {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--accent);
  background: rgba(217, 119, 6, 0.12);
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  transition: var(--transition);
  flex-shrink: 0;
}

.dropdown-info {
  display: flex;
  flex-direction: column;
}

.dropdown-info strong {
  font-size: 0.85rem;
  color: var(--dark);
  line-height: 1.25;
}

.dropdown-info small {
  font-size: 0.75rem;
  color: var(--gray-500);
  line-height: 1.2;
}

.dropdown-all {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 0.75rem;
  margin-top: 0.35rem;
  border-top: 1px solid var(--gray-100);
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--accent);
  border-radius: var(--radius-sm);
}

.dropdown-all svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.dropdown-all:hover {
  background-color: rgba(217, 119, 6, 0.08);
}

/* Button Component Styles */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
  white-space: nowrap;
}

.btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  flex-shrink: 0;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--white);
  box-shadow: 0 4px 12px rgba(13, 40, 71, 0.2);
}

.btn-primary:hover {
  background-color: var(--primary-light);
  box-shadow: 0 6px 16px rgba(13, 40, 71, 0.3);
}

.btn-accent {
  background-color: var(--accent);
  color: var(--white);
  box-shadow: 0 4px 12px rgba(217, 119, 6, 0.25);
}

.btn-accent:hover {
  background-color: var(--accent-hover);
  box-shadow: 0 6px 16px rgba(217, 119, 6, 0.35);
}

.btn-outline {
  border: 2px solid var(--white);
  color: var(--white);
  background: transparent;
}

.btn-outline:hover {
  background: var(--white);
  color: var(--primary);
}

.btn-secondary {
  border: 1.5px solid var(--gray-300);
  color: var(--gray-700);
  background: var(--white);
}

.btn-secondary:hover {
  background: var(--gray-100);
  color: var(--dark);
  border-color: var(--gray-400);
}

.btn-sm {
  padding: 0.5rem 1.1rem;
  font-size: 0.85rem;
}

/* Button Loading Spinner */
@keyframes btnSpinner {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.btn-spinner,
.btn svg.btn-spinner {
  width: 18px !important;
  height: 18px !important;
  animation: btnSpinner 0.85s linear infinite !important;
  vertical-align: middle;
  flex-shrink: 0;
  fill: none !important;
  stroke: none;
}

.btn-spinner circle,
.btn svg.btn-spinner circle,
.btn-spinner path,
.btn svg.btn-spinner path {
  fill: none !important;
}

/* Mobile Toggle Hamburger */
.mobile-toggle {
  display: none;
  background: transparent;
  cursor: pointer;
  padding: 0.4rem;
  border-radius: var(--radius-sm);
  color: var(--primary);
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  position: relative;
  z-index: 1002;
}

.toggle-bar {
  display: block;
  width: 22px;
  height: 2px;
  background-color: var(--primary);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.mobile-toggle.active .toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.mobile-toggle.active .toggle-bar:nth-child(2) {
  opacity: 0;
}

.mobile-toggle.active .toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Nav Backdrop Overlay */
.nav-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(3px);
  z-index: 998;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.nav-backdrop.active {
  display: block;
  opacity: 1;
}

/* Hero Section */
.hero {
  position: relative;
  background: linear-gradient(135deg, rgba(7, 23, 43, 0.92) 0%, rgba(13, 40, 71, 0.85) 100%), 
              url('../images/2_Oil_and_Gas_Surface_Pipeline_Offshore_Services/offshore_oil_and_gas_production_platform.jpeg') center/cover no-repeat;
  color: var(--white);
  padding: 1.75rem 0 4.5rem;
  min-height: auto;
  display: flex;
  align-items: flex-start;
}

.hero-content {
  max-width: 820px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
  padding: 0.45rem 1.1rem;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.25);
  margin-bottom: 1.25rem;
  color: #fbbf24;
}

.hero-badge svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.hero h1 {
  color: var(--white);
  margin-bottom: 1.25rem;
  letter-spacing: -0.02em;
}

.hero p {
  font-size: 1.2rem;
  line-height: 1.6;
  color: var(--gray-200);
  margin-bottom: 2.25rem;
  max-width: 720px;
}

.hero-actions {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
  margin-bottom: 3.5rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 2rem;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.1;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--gray-300);
  margin-top: 0.35rem;
  font-weight: 500;
}

/* Section Common Styling */
.section {
  padding: 5.5rem 0;
}

.section-bg-light {
  background-color: var(--gray-50);
}

.section-bg-dark {
  background-color: var(--primary-dark);
  color: var(--white);
}

.section-bg-dark h2, .section-bg-dark h3, .section-bg-dark h4 {
  color: var(--white);
}

.section-bg-dark p {
  color: var(--gray-300);
}

/* About Section */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  align-items: center;
}

.about-image-wrapper {
  position: relative;
}

.about-images-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  width: 100%;
}

.about-photo-card {
  position: relative;
  width: 100%;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  background: var(--navy-900);
}

.about-photo-card img,
.about-main-img {
  border-radius: var(--radius-lg);
  width: 100%;
  height: 480px;
  object-fit: cover;
  display: block;
}

/* Individual photos height when 2 or 3 photos are displayed */
.about-images-list.multi-photos .about-photo-card img {
  height: 280px;
}

.about-photo-number-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(10, 25, 47, 0.85);
  backdrop-filter: blur(4px);
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.6rem;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  z-index: 10;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.about-badge-card {
  position: absolute;
  bottom: -20px;
  right: -20px;
  background: var(--white);
  padding: 1.5rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-xl);
  border-left: 5px solid var(--accent);
  max-width: 260px;
  z-index: 25 !important;
}

.about-badge-card h4 {
  font-size: 1.1rem;
  color: var(--primary);
  margin-bottom: 0.25rem;
}

.about-badge-card p {
  font-size: 0.85rem;
  color: var(--gray-600);
}

.about-text h2 {
  margin-bottom: 1.25rem;
}

.about-text p {
  margin-bottom: 1.25rem;
  color: var(--gray-600);
}

.about-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-top: 2rem;
}

.feature-pill {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.feature-pill svg {
  width: 20px;
  height: 20px;
  fill: var(--accent);
  flex-shrink: 0;
  margin-top: 3px;
}

.feature-pill span {
  font-weight: 600;
  color: var(--gray-800);
  font-size: 0.95rem;
}

/* Core Divisions / Activities Section */
.division-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  margin-bottom: 2.5rem;
  border: 1px solid var(--gray-200);
}

.division-card:hover {
  box-shadow: var(--shadow-xl);
  border-color: rgba(217, 119, 6, 0.35);
}

.division-card.reverse {
  grid-template-columns: 1.1fr 1fr;
}

.division-card.reverse .division-image {
  order: 2;
}

.division-card.reverse .division-body {
  order: 1;
}

.division-image {
  position: relative;
  overflow: hidden;
  min-height: 320px;
}

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

.division-card:hover .division-image img {
  transform: scale(1.05);
}

.division-badge {
  position: absolute;
  top: 1.25rem;
  left: 1.25rem;
  background: rgba(7, 23, 43, 0.85);
  color: var(--white);
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.division-body {
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.division-body h3 {
  color: var(--primary);
  margin-bottom: 0.75rem;
}

.division-body p {
  color: var(--gray-600);
  margin-bottom: 1.5rem;
  font-size: 0.975rem;
}

.division-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem 1rem;
  margin-bottom: 1.75rem;
}

.division-list li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--gray-700);
}

.division-list li svg {
  width: 16px;
  height: 16px;
  fill: var(--accent);
  flex-shrink: 0;
}

/* Gallery Showcase */
.gallery-filters {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.filter-btn {
  padding: 0.5rem 1.25rem;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--gray-700);
  cursor: pointer;
  transition: var(--transition);
}

.filter-btn:hover, .filter-btn.active {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
  gap: 1.5rem;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  background: var(--gray-100);
  aspect-ratio: 4 / 3;
  cursor: pointer;
}

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

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(7, 23, 43, 0.9) 0%, rgba(7, 23, 43, 0.2) 60%, transparent 100%);
  opacity: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  transition: opacity 0.3s ease;
}

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

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

.gallery-overlay h4 {
  color: var(--white);
  font-size: 1.05rem;
  margin-bottom: 0.25rem;
}

.gallery-overlay span {
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
}

.gallery-zoom-icon {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
}

.gallery-zoom-icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* Quality & HSE */
.hse-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 2rem;
}

.hse-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 2.25rem;
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.hse-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--accent);
}

.hse-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: rgba(217, 119, 6, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  margin-bottom: 1.25rem;
}

.hse-icon svg {
  width: 26px;
  height: 26px;
  fill: currentColor;
}

.hse-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

/* Contact & Quote Section */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 3.5rem;
}

.contact-info-panel {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-info-card {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border-top: 4px solid var(--accent);
}

.contact-block {
  display: flex;
  align-items: flex-start;
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.contact-block:last-child {
  margin-bottom: 0;
}

.contact-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(13, 40, 71, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}

.contact-icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.contact-detail h4 {
  font-size: 1rem;
  color: var(--dark);
  margin-bottom: 0.2rem;
}

.contact-detail p, .contact-detail a {
  font-size: 0.95rem;
  color: var(--gray-600);
  word-break: break-word;
  overflow-wrap: anywhere;
}

.contact-detail a:hover {
  color: var(--accent);
}

.whatsapp-card {
  background: linear-gradient(135deg, #128c7e 0%, #075e54 100%);
  color: var(--white);
  padding: 2rem;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  box-shadow: var(--shadow-lg);
}

.whatsapp-card h4 {
  color: var(--white);
  font-size: 1.2rem;
  margin-bottom: 0.25rem;
}

.whatsapp-card p {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.875rem;
}

.contact-form-panel {
  background: var(--white);
  padding: 2.75rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--gray-200);
}

.contact-form-panel h3 {
  margin-bottom: 0.5rem;
  color: var(--primary);
}

.contact-form-panel > p {
  color: var(--gray-600);
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--gray-800);
  margin-bottom: 0.35rem;
}

.form-control {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding: 0.75rem 1rem;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius-md);
  background: var(--gray-50);
  color: var(--gray-800);
  transition: var(--transition);
}

.form-control:focus {
  background: var(--white);
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(13, 40, 71, 0.15);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

/* Custom Modular Division Selector Trigger */
/* Custom Modular Division Selector Trigger */
.division-picker-trigger {
  width: 100%;
  max-width: 100%;
  padding: 0.75rem 0.85rem;
  border: 1.5px solid var(--gray-300);
  border-radius: var(--radius-md);
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
  box-sizing: border-box;
  min-width: 0;
  overflow: hidden;
}

.division-picker-trigger:hover,
.division-picker-trigger:focus {
  border-color: var(--accent);
  background: rgba(217, 119, 6, 0.02);
  box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.15);
  outline: none;
}

.division-picker-trigger.is-invalid {
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
}

.picker-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
}

.picker-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: rgba(217, 119, 6, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}

.picker-icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.picker-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}

.picker-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--primary);
  line-height: 1.35;
  white-space: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
}

.picker-label.placeholder {
  color: var(--gray-500);
  font-weight: 500;
}

.picker-sub {
  font-size: 0.72rem;
  color: var(--gray-500);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.picker-action {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.picker-badge {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--white);
  background: var(--primary);
  padding: 0.25rem 0.6rem;
  border-radius: 9999px;
  letter-spacing: 0.02em;
}

.picker-action svg {
  width: 18px;
  height: 18px;
  fill: var(--gray-400);
  transition: transform 0.2s ease;
}

.division-picker-trigger:hover .picker-action svg {
  fill: var(--accent);
}

/* Service Division Modular Modal Dialog */
.division-modal-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: rgba(7, 23, 43, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 999999 !important;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  box-sizing: border-box;
}

.division-modal-overlay.active {
  display: flex;
}

.division-modal-container {
  background: var(--white);
  width: 100%;
  max-width: 780px;
  max-height: 88vh;
  border-radius: var(--radius-xl);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transform: scale(0.95);
  transition: transform 0.25s ease;
}

.division-modal-overlay.active .division-modal-container {
  transform: scale(1);
}

.division-modal-header {
  padding: 1.5rem 1.75rem;
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  background: var(--gray-50);
}

.division-modal-header h3 {
  font-size: 1.35rem;
  color: var(--primary);
  margin: 0.25rem 0 0.15rem;
}

.division-modal-header p {
  font-size: 0.875rem;
  color: var(--gray-600);
}

.division-modal-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid var(--gray-300);
  color: var(--gray-700);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: var(--transition);
}

.division-modal-close svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.division-modal-close:hover {
  background: var(--gray-200);
  color: var(--dark);
}

.division-modal-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  padding: 1.5rem 1.75rem;
  overflow-y: auto;
  max-height: 55vh;
}

.division-option-card {
  background: var(--white);
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 1.15rem;
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
  position: relative;
  display: flex;
  flex-direction: column;
}

.option-thumb-wrap {
  width: 100%;
  height: 120px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-bottom: 0.75rem;
  background: var(--gray-100);
}

.option-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.division-option-card:hover .option-thumb-img {
  transform: none;
}

.division-option-card:hover {
  border-color: var(--primary-light);
  background: var(--gray-50);
  box-shadow: var(--shadow-sm);
}

.division-option-card.selected {
  border-color: var(--accent);
  background: rgba(217, 119, 6, 0.04);
  box-shadow: 0 0 0 1px var(--accent);
}

.option-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.65rem;
}

.option-badge {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(13, 40, 71, 0.1);
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-sm);
}

.division-option-card.selected .option-badge {
  background: var(--accent);
  color: var(--white);
}

.option-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--gray-300);
  display: flex;
  align-items: center;
  justify-content: center;
  color: transparent;
  transition: all 0.2s ease;
}

.option-check svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.division-option-card.selected .option-check {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}

.division-option-card h4 {
  font-size: 0.98rem;
  color: var(--primary);
  line-height: 1.3;
  margin-bottom: 0.35rem;
}

.division-option-card p {
  font-size: 0.8rem;
  color: var(--gray-600);
  line-height: 1.4;
  margin-top: auto;
}

.division-modal-footer {
  padding: 1rem 1.75rem;
  border-top: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1rem;
  background: var(--gray-50);
}

/* Lightbox Modal */
.modal-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(7, 23, 43, 0.92);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  backdrop-filter: blur(8px);
}

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

.modal-content {
  max-width: 900px;
  width: 100%;
  position: relative;
  background: var(--dark);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.modal-image {
  width: 100%;
  max-height: 75vh;
  object-fit: contain;
}

.modal-caption {
  padding: 1rem 1.5rem;
  color: var(--white);
  font-size: 1rem;
  font-weight: 600;
  background: rgba(0, 0, 0, 0.6);
}

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.modal-close:hover {
  background: var(--accent);
}

.modal-close svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* Site Footer */
.site-footer {
  background: var(--primary-dark);
  color: var(--gray-300);
  padding: 5rem 0 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1.2fr 1.5fr;
  gap: 3rem;
  margin-bottom: 3.5rem;
}

.footer-brand .brand-logo {
  margin-bottom: 1.25rem;
}

.footer-brand .brand-logo img {
  filter: brightness(0) invert(1);
}

.footer-brand .brand-title {
  color: var(--white);
}

.footer-brand .brand-sub {
  color: var(--accent);
}

.footer-brand p {
  font-size: 0.9rem;
  color: var(--gray-400);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.footer-col h4 {
  color: var(--white);
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  position: relative;
  padding-bottom: 0.65rem;
}

.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 32px;
  height: 2px;
  background: var(--accent);
}

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: var(--gray-400);
  font-size: 0.9rem;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.footer-links a svg {
  width: 12px;
  height: 12px;
  fill: var(--accent);
}

.footer-links a:hover {
  color: var(--white);
  padding-left: 4px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: var(--gray-500);
  flex-wrap: wrap;
  gap: 1rem;
}

/* Toast Message */
.form-toast {
  display: none;
  background: #065f46;
  color: var(--white);
  padding: 1rem 1.25rem;
  border-radius: var(--radius-md);
  margin-bottom: 1.25rem;
  font-size: 0.9rem;
  align-items: center;
  gap: 0.75rem;
}

.form-toast svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
  flex-shrink: 0;
}

/* Responsive Media Queries */
@media (max-width: 1140px) {
  /* Hide the top utility bar completely whenever hamburger menu is active */
  .top-bar {
    display: none !important;
  }

  /* Sticky site header at top of viewport with zero gap */
  .site-header {
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 1000 !important;
  }

  body {
    padding-top: 0 !important;
  }

  .hero {
    padding: 1.5rem 0 3.5rem;
    min-height: auto;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .hse-grid {
    grid-template-columns: 1fr 1fr;
  }
  
  /* Mobile Navigation Drawer */
  .mobile-toggle {
    display: flex;
  }

  .nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: var(--white);
    flex-direction: column;
    align-items: stretch;
    padding: 1.25rem 1.5rem 2rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15);
    border-top: 1px solid var(--gray-200);
    border-bottom: 3px solid var(--accent);
    max-height: calc(100vh - 85px);
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
    gap: 0.25rem;
    z-index: 1001;
  }

  .nav-menu.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .nav-link {
    padding: 0.85rem 0.5rem;
    font-size: 1.05rem;
    border-bottom: 1px solid var(--gray-100);
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .nav-link::after {
    display: none;
  }

  .nav-link.active {
    color: var(--accent);
    font-weight: 700;
  }

  .nav-item-dropdown {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }

  .nav-dropdown-menu {
    position: static !important;
    left: auto !important;
    top: auto !important;
    transform: none !important;
    width: 100% !important;
    max-width: 100% !important;
    box-shadow: none !important;
    border: none !important;
    margin: 0.35rem 0 0.5rem 0;
    padding: 0.5rem 0.65rem;
    background: var(--gray-50);
    border-radius: var(--radius-md);
    border-left: 3px solid var(--accent);
    display: none;
    opacity: 1 !important;
    visibility: visible !important;
    box-sizing: border-box;
  }

  .nav-item-dropdown.mobile-open .nav-dropdown-menu {
    display: block !important;
    transform: none !important;
  }

  .nav-item-dropdown:not(.mobile-open) .nav-dropdown-menu {
    display: none !important;
  }

  .nav-item-dropdown:hover .nav-dropdown-menu,
  .nav-item-dropdown:focus-within .nav-dropdown-menu {
    transform: none !important;
  }

  .nav-item-dropdown.mobile-open .dropdown-chevron {
    transform: rotate(180deg);
  }

  .dropdown-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.7rem 0.65rem;
    width: 100%;
    box-sizing: border-box;
    border-radius: var(--radius-sm);
  }

  .dropdown-info {
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
  }

  .dropdown-info strong {
    font-size: 0.9rem;
    color: var(--dark);
    display: block;
    line-height: 1.3;
    white-space: normal;
    word-break: break-word;
  }

  .dropdown-info small {
    font-size: 0.76rem;
    color: var(--gray-500);
    display: block;
    line-height: 1.3;
    margin-top: 2px;
    white-space: normal;
    word-break: break-word;
  }

  .dropdown-all {
    width: 100%;
    box-sizing: border-box;
    padding: 0.75rem 0.65rem;
    margin-top: 0.5rem;
  }

  .nav-cta {
    width: 100%;
    margin-top: 1.25rem;
  }

  .nav-cta .btn {
    width: 100%;
    padding: 0.85rem;
    font-size: 1rem;
  }
}

@media (max-width: 868px) {
  section[id], article[id], .division-card[id] {
    scroll-margin-top: 75px;
  }
  
  .section {
    padding: 4rem 0;
  }
  
  .section-header {
    margin-bottom: 2.5rem;
  }

  .about-grid, .contact-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  
  .about-badge-card {
    position: static !important;
    margin-top: 1rem;
    max-width: 100%;
    z-index: 5 !important;
  }
  
  .about-photo-card img,
  .about-main-img {
    height: 320px;
  }

  .about-images-list.multi-photos .about-photo-card img {
    height: 240px;
  }
  
  .division-card, .division-card.reverse {
    grid-template-columns: 1fr;
    margin-bottom: 2rem;
  }
  
  .division-image {
    min-height: 220px;
    height: 240px;
  }
  
  .division-body {
    padding: 1.75rem 1.5rem;
  }

  .division-card.reverse .division-image {
    order: 1;
  }
  
  .division-card.reverse .division-body {
    order: 2;
  }
  
  .hero {
    padding: 1.5rem 0 3.5rem;
    min-height: auto;
  }
  
  .hero-stats {
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
  }
  
  .contact-form-panel {
    padding: 2rem 1.75rem;
  }
}

@media (max-width: 768px) {
  .hero {
    padding: 1.15rem 0 3.5rem;
    min-height: auto;
  }

  .container {
    padding: 0 1.25rem;
  }

  .section {
    padding: 3.5rem 0;
  }

  .section-header {
    margin-bottom: 2rem;
  }

  /* Form & inputs */
  .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .form-control {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  .division-list {
    grid-template-columns: 1fr;
  }

  .about-features {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }

  /* Horizontal swipeable gallery filter tabs without expanding page */
  .gallery-filters {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 0.75rem;
    justify-content: flex-start;
    gap: 0.5rem;
    scrollbar-width: none;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }
  
  .gallery-filters::-webkit-scrollbar {
    display: none;
  }
  
  .filter-btn {
    flex-shrink: 0;
    padding: 0.45rem 0.9rem;
    font-size: 0.825rem;
    white-space: nowrap;
  }
  
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .hse-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

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

  .contact-info-card {
    padding: 1.5rem 1.25rem;
  }

  .whatsapp-card {
    flex-direction: column;
    align-items: stretch;
    text-align: left;
    gap: 1.25rem;
    padding: 1.5rem;
  }
  
  .whatsapp-card .btn {
    width: 100%;
    justify-content: center;
  }

  /* Division Modal Responsive */
  .division-modal-overlay {
    padding: 0.75rem;
  }

  .division-modal-container {
    width: 100%;
    max-height: 92vh;
    border-radius: var(--radius-lg);
  }

  .division-modal-header {
    padding: 1.15rem 1.25rem;
  }

  .division-modal-header h3 {
    font-size: 1.2rem;
  }

  .division-modal-grid {
    grid-template-columns: 1fr;
    padding: 1rem 1.25rem;
    gap: 0.85rem;
    max-height: 58vh;
  }

  .division-option-card {
    padding: 1rem;
  }
  
  .division-modal-footer {
    padding: 0.85rem 1.25rem;
    flex-direction: column-reverse;
    align-items: stretch;
    gap: 0.65rem;
  }

  .division-modal-footer .btn {
    width: 100%;
    justify-content: center;
  }

  .picker-badge {
    display: none;
  }
}

@media (max-width: 640px) {
  .hero-stats {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .hero-actions .btn {
    width: 100%;
  }

  .division-picker-trigger {
    padding: 0.65rem 0.85rem;
  }
  
  .picker-icon {
    width: 32px;
    height: 32px;
  }
  
  .picker-label {
    font-size: 0.875rem;
  }

  .contact-form-panel {
    padding: 1.5rem 1.15rem;
  }
}

@media (max-width: 480px) {
  body {
    padding-top: 0 !important;
  }

  .container {
    padding: 0 1rem;
  }

  .hero {
    padding: 0.75rem 0 3rem;
  }

  .hero-badge {
    margin-bottom: 0.85rem;
    font-size: 0.8rem;
    padding: 0.35rem 0.85rem;
  }

  .brand-logo img {
    width: 40px;
    height: 40px;
  }
  
  .brand-title {
    font-size: 0.95rem;
  }
  
  .brand-sub {
    font-size: 0.62rem;
  }
  
  .nav-container {
    padding: 0.65rem 0.85rem;
  }

  .hero h1 {
    font-size: 1.85rem;
  }

  .hero p {
    font-size: 1rem;
  }

  .about-main-img {
    height: 250px;
  }

  .contact-form-panel {
    padding: 1.25rem 0.85rem;
  }

  .division-picker-trigger {
    padding: 0.6rem 0.75rem;
  }

  .division-modal-overlay {
    padding: 0.5rem;
  }

  .division-modal-header {
    padding: 1rem;
  }

  .division-modal-grid {
    padding: 0.75rem;
    max-height: 55vh;
  }

  .division-modal-footer {
    padding: 0.75rem;
  }
}

/* ==========================================================================
   Modular Custom Dialog Modal (Alert / Confirm)
   ========================================================================== */
.dialog-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  opacity: 0;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.dialog-modal-overlay.active {
  display: flex;
  opacity: 1;
}

.dialog-modal-container {
  width: 100%;
  max-width: 480px;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.35), 0 0 0 1px rgba(15, 23, 42, 0.08);
  border: 1px solid var(--gray-200);
  overflow: hidden;
  transform: translateY(-12px) scale(0.97);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.dialog-modal-overlay.active .dialog-modal-container {
  transform: translateY(0) scale(1);
}

.dialog-modal-header {
  padding: 1.25rem 1.5rem;
  background: var(--gray-50);
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  gap: 1rem;
  position: relative;
}

.dialog-icon-wrapper {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dialog-icon-wrapper.info {
  background: rgba(59, 130, 246, 0.12);
  color: #3b82f6;
}

.dialog-icon-wrapper.warning {
  background: rgba(217, 119, 6, 0.12);
  color: var(--accent);
}

.dialog-icon-wrapper.danger {
  background: rgba(239, 68, 68, 0.12);
  color: #ef4444;
}

.dialog-icon-wrapper svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.dialog-header-text {
  flex: 1;
}

.dialog-header-text h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dark);
  margin: 0;
  line-height: 1.3;
}

.dialog-header-text p {
  font-size: 0.75rem;
  color: var(--gray-500);
  margin: 0.15rem 0 0 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.dialog-modal-body {
  padding: 1.5rem;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--gray-700);
  background: var(--white);
}

.dialog-modal-footer {
  padding: 1rem 1.5rem;
  background: var(--gray-50);
  border-top: 1px solid var(--gray-200);
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

/* ==========================================================================
   Modular Core Divisions Modal Menu & Dynamic Cards
   ========================================================================== */
#navDivisionsModal .division-modal-container {
  max-width: 1040px;
  width: 95%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.25);
  overflow: hidden;
}

#navDivisionsModal .division-modal-header {
  padding: 1.25rem 1.75rem;
  border-bottom: 1px solid var(--gray-200);
  background: var(--gray-50);
}

.nav-divisions-modal-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.15rem;
  padding: 1.5rem 1.75rem;
  overflow-y: auto;
  max-height: calc(85vh - 160px);
  min-height: 250px;
  flex: 1 1 auto;
  background: #f8fafc;
  box-sizing: border-box;
  width: 100%;
}

/* Horizontal card design on both Desktop and Mobile */
.nav-division-card {
  background: var(--white);
  border: 1.5px solid var(--gray-200);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  min-height: 82px;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  position: relative;
  cursor: pointer;
}

/* No upward movement on hover */
.nav-division-card:hover {
  transform: none !important;
  border-color: var(--primary);
  background: #fbfcfe;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.09);
}

.nav-division-thumb-wrap {
  width: 120px;
  min-width: 120px;
  height: auto;
  position: relative;
  overflow: hidden;
  background: var(--primary);
  flex-shrink: 0;
}

.nav-division-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.nav-division-card:hover .nav-division-thumb-img {
  transform: none;
}

.nav-division-badge-overlay {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(15, 23, 42, 0.9);
  color: var(--accent);
  border: 1px solid rgba(245, 158, 11, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0.18rem 0.5rem;
  border-radius: var(--radius-sm);
  z-index: 2;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
}

.nav-division-card-content {
  padding: 0.85rem 1.1rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex: 1;
  min-width: 0;
  background: transparent;
}

.nav-division-card-content h4 {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--dark) !important;
  margin: 0;
  line-height: 1.35;
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  visibility: visible !important;
}

.nav-division-card-arrow {
  flex-shrink: 0;
  color: var(--gray-400);
  transition: color 0.2s ease;
}

.nav-division-card:hover .nav-division-card-arrow {
  color: var(--accent);
}

/* Hide description paragraph and actions */
.nav-division-card-content p,
.nav-division-card-actions {
  display: none !important;
}

/* Tablet & Mobile Specific Rules */
@media (max-width: 768px) {
  #navDivisionsModal .division-modal-container {
    width: 95%;
    max-height: 94vh;
  }

  #navDivisionsModal .division-modal-header {
    padding: 1rem 1.15rem;
  }

  #navDivisionsModal .division-modal-header h3 {
    font-size: 1.15rem;
  }

  #navDivisionsModal .division-modal-header p {
    font-size: 0.78rem;
  }

  .nav-divisions-modal-grid {
    grid-template-columns: 1fr;
    gap: 0.85rem;
    padding: 0.85rem;
    max-height: calc(90vh - 145px);
    min-height: 280px;
    flex: 1 1 auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
    width: 100%;
  }

  .nav-division-card {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch !important;
    height: auto !important;
    min-height: 74px !important;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
  }

  .nav-division-thumb-wrap {
    width: 85px;
    min-width: 85px;
    align-self: stretch;
    display: flex;
    flex-direction: column;
    position: relative;
    flex-shrink: 0;
  }

  .nav-division-thumb-img {
    height: 100%;
    width: 100%;
    object-fit: cover;
    display: block;
    flex: 1;
  }

  .nav-division-badge-overlay {
    top: 6px;
    left: 6px;
    font-size: 0.6rem;
    padding: 0.12rem 0.38rem;
    line-height: 1.1;
  }

  .nav-division-card-content {
    padding: 0.65rem 0.85rem !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    flex: 1 !important;
    min-width: 0 !important;
  }

  .nav-division-card-content h4 {
    font-size: 0.84rem;
    line-height: 1.3;
    margin: 0 !important;
    word-break: normal;
    overflow-wrap: break-word;
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 0.4rem;
  }

  .nav-division-card-actions {
    display: none !important;
  }

  #navDivisionsModal .division-modal-footer {
    padding: 0.75rem 1rem;
    flex-direction: column;
    gap: 0.65rem;
    text-align: center;
  }

  #navDivisionsModal .division-modal-footer .btn {
    width: 100%;
    justify-content: center;
  }
}

/* Universal guard: prevent buttons, tabs, links, and cards from translating upward on hover */
button:hover,
.btn:hover,
.btn-primary:hover,
.btn-accent:hover,
.btn-secondary:hover,
.btn-outline:hover,
.btn-xs:hover,
.btn-sm:hover,
.nav-link:hover,
.social-link:hover,
.filter-btn:hover,
.division-picker-trigger:hover,
.division-option-card:hover,
.nav-division-card:hover,
.modal-close:hover,
.division-modal-close:hover {
  transform: none !important;
}



