/* ============================================
   CLEANROOM PRODUCTS - MASTER UI DESIGN
   ============================================
   Scoped styles for Cleanroom Products section.
   Features:
   - Background: Subtle "Floating Blobs" animation
   - Typography: Playfair Display (Headings) + Source Sans Pro (Body)
   - Cards: Clean, elevated design with hover lift
   - Dark Mode: Fully supported
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700&family=Source+Sans+Pro:wght@300;400;600&display=swap');

/* Variables */
#cleanroom-products-section {
  --cp-bg-light: #f8fbfd;
  --cp-bg-dark: #0f172a;
  --cp-primary: #004685;
  --cp-accent: #29afe3;
  --cp-text-dark: #1e293b;
  --cp-text-light: #f1f5f9;
  --cp-card-bg-light: #ffffff;
  --cp-card-bg-dark: #1e293b;
}

/* Section Container */
#cleanroom-products-section {
  position: relative;
  background-color: var(--cp-bg-light);
  overflow: hidden;
  isolation: isolate;
  font-family: 'Source Sans Pro', sans-serif;
  padding: 80px 0;
}

/* ============================================
   BACKGROUND ANIMATION
   ============================================ */
.cp-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.cp-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.12;
  animation: cp-float infinite ease-in-out alternate;
}

.cp-blob-1 {
  top: -10%;
  left: -10%;
  width: 600px;
  height: 600px;
  background: var(--cp-accent);
  animation-duration: 25s;
}

.cp-blob-2 {
  bottom: -10%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: var(--cp-primary);
  animation-duration: 30s;
  animation-delay: -5s;
}

.cp-blob-3 {
  top: 30%;
  left: 40%;
  width: 400px;
  height: 400px;
  background: var(--cp-accent);
  opacity: 0.08;
  animation-duration: 20s;
  animation-delay: -10s;
}

@keyframes cp-float {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, 60px) scale(1.1); }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .cp-blob {
    animation: none;
  }
}

/* ============================================
   CONTENT STYLING
   ============================================ */

/* Headings */
#cleanroom-products-section .section-head h2 {
  font-family: 'Playfair Display', serif;
  color: var(--cp-primary);
  font-weight: 700;
  font-size: 2.5rem;
  margin-bottom: 15px;
}

#cleanroom-products-section .section-head p {
  color: #64748b;
  font-size: 1.1rem;
  max-width: 700px;
  margin: 0 auto 40px;
}

/* Cards */
#cleanroom-products-section .wt-box {
  background: var(--cp-card-bg-light);
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.04);
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  border: 1px solid rgba(0,0,0,0.03);
  height: 100%;
  overflow: hidden;
  position: relative;
}

#cleanroom-products-section .wt-box:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

/* Image Area */
#cleanroom-products-section .wt-thum-bx {
  overflow: hidden;
  position: relative;
}

#cleanroom-products-section .wt-thum-bx img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  transition: transform 0.6s ease;
}

#cleanroom-products-section .wt-box:hover .wt-thum-bx img {
  transform: scale(1.08);
}

/* Icons */
#cleanroom-products-section .wt-icon-box-sm {
  background-color: var(--cp-primary);
  color: #fff;
  border-radius: 50%;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  bottom: -28px;
  right: 24px;
  box-shadow: 0 4px 12px rgba(0,70,133,0.3);
  z-index: 2;
}

#cleanroom-products-section .wt-icon-box-sm i {
  font-size: 24px;
  color: #ffffff;
}

/* Card Content */
#cleanroom-products-section .p-a20 {
  padding: 40px 24px 24px; /* Top padding accounts for icon overlap */
}

#cleanroom-products-section h4.wt-tilte {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--cp-text-dark);
  margin-bottom: 15px;
}

#cleanroom-products-section p {
  color: #64748b;
  line-height: 1.6;
  font-size: 1rem;
  margin-bottom: 20px;
}

/* Read More Link */
#cleanroom-products-section .site-button-link {
  color: var(--cp-accent);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-size: 0.85rem;
  text-decoration: none;
  position: relative;
  display: inline-block;
}

#cleanroom-products-section .site-button-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--cp-accent);
  transition: width 0.3s ease;
}

#cleanroom-products-section .site-button-link:hover::after {
  width: 100%;
}

/* ============================================
   DARK MODE
   ============================================ */
/* REMOVED: @media (prefers-color-scheme: dark) - Dark mode is now user-activated only via body.dark-mode or html[data-theme="dark"] class. See docs/workflow/dark-mode.md */
  
  #cleanroom-products-section .section-head h2 {
    color: #ffffff;
  }
  
  #cleanroom-products-section .wt-box {
    background: var(--cp-card-bg-dark);
    border-color: rgba(255,255,255,0.05);
  }
  
  #cleanroom-products-section h4.wt-tilte {
    color: var(--cp-text-light);
  }
  
  #cleanroom-products-section p {
    color: #94a3b8;
  }
  
  .cp-blob {
    opacity: 0.08;
  }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  #cleanroom-products-section .wt-thum-bx img {
    height: 200px;
  }
  
  #cleanroom-products-section .section-head h2 {
    font-size: 2rem;
  }
}
/* ==========================================================================
   Cleanroom Windows - Industries Slider Redesign
   Unique, Premium, Center-Focused Design
   ========================================================================== */

/* 1. Scoped Variables for this Section */
#industries-we-serve-section {
    --cr-primary: #004685;
    --cr-accent: #29afe3;
    --cr-glass: rgba(255, 255, 255, 0.95);
    --cr-glass-dark: rgba(20, 30, 40, 0.85);
    --cr-border: rgba(41, 175, 227, 0.2);
    --cr-shadow: 0 15px 40px rgba(0, 70, 133, 0.15);
    --cr-transition: cubic-bezier(0.2, 0.8, 0.2, 1);

    position: relative;
    overflow: hidden;
    padding-top: 100px;
    padding-bottom: 100px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbfe 100%);
}

[data-theme="dark"] #industries-we-serve-section {
    background: linear-gradient(180deg, #121212 0%, #0a1520 100%);
    --cr-glass: rgba(30, 40, 50, 0.9);
    --cr-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

/* 2. Abstract Background Animation (Data Streams) */
#industries-we-serve-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(41, 175, 227, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(0, 70, 133, 0.05) 0%, transparent 50%);
    z-index: 0;
    pointer-events: none;
}

.tech-grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: 40px 40px;
    background-image: linear-gradient(to right, rgba(41, 175, 227, 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(41, 175, 227, 0.05) 1px, transparent 1px);
    mask-image: radial-gradient(circle at center, black 40%, transparent 100%);
    -webkit-mask-image: radial-gradient(circle at center, black 40%, transparent 100%);
    z-index: 0;
    pointer-events: none;
    animation: panGrid 60s linear infinite;
}

@keyframes panGrid {
    0% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(40px);
    }
}

/* 3. Section Header Refinement */
#industries-we-serve-section .section-head {
    position: relative;
    z-index: 2;
    margin-bottom: 60px;
}

#industries-we-serve-section .section-head h2 {
    font-weight: 800;
    font-size: 3rem;
    letter-spacing: -1px;
    margin-top: 10px;
}

/* 4. Carousel Container */
.cleanroom-window-slider {
    position: relative;
    z-index: 5;
    padding: 20px 0;
}

.cleanroom-window-slider .owl-stage-outer {
    overflow: visible;
    /* Allow shadow and scale to show */
    padding: 40px 0;
    /* Space for scale effect */
}

/* 5. Cleanroom Card Design */
.cleanroom-card {
    position: relative;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    height: 500px;
    transition: all 0.5s var(--cr-transition);
    transform: scale(0.9);
    opacity: 0.5;
    filter: grayscale(80%);
    box-shadow: none;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] .cleanroom-card {
    background: #1e252b;
    border-color: rgba(255, 255, 255, 0.05);
}

/* Center Active Item State */
.cleanroom-window-slider .center .cleanroom-card {
    transform: scale(1.05);
    opacity: 1;
    filter: grayscale(0%);
    box-shadow: var(--cr-shadow);
    z-index: 10;
    border: 1px solid var(--cr-accent);
}

/* Image Viewport */
.card-image-viewport {
    height: 65%;
    width: 100%;
    position: relative;
    overflow: hidden;
}

.card-image-viewport img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
}

.cleanroom-window-slider .center .cleanroom-card:hover .card-image-viewport img {
    transform: scale(1.1);
}

/* Holographic Overlay on Image */
.card-overlay-scan {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, rgba(41, 175, 227, 0) 0%, rgba(0, 70, 133, 0.4) 100%);
    opacity: 0.6;
    transition: opacity 0.5s;
}

.cleanroom-window-slider .center .cleanroom-card:hover .card-overlay-scan {
    opacity: 0.3;
}

/* Scan Line Animation */
.card-overlay-scan::after {
    content: '';
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    height: 50px;
    background: linear-gradient(180deg, transparent, rgba(41, 175, 227, 0.5), transparent);
    animation: none;
}

.cleanroom-window-slider .center .cleanroom-card:hover .card-overlay-scan::after {
    animation: scanLine 2s linear infinite;
}

@keyframes scanLine {
    0% {
        top: -100%;
    }

    100% {
        top: 200%;
    }
}

/* 6. Card Content Area */
.card-content {
    height: 35%;
    padding: 25px;
    position: relative;
    background: var(--cr-glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: background 0.3s;
}

[data-theme="dark"] .card-content {
    background: var(--cr-glass-dark);
}

.industry-icon {
    position: absolute;
    top: -25px;
    right: 25px;
    width: 50px;
    height: 50px;
    background: var(--cr-accent);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 5px 15px rgba(41, 175, 227, 0.4);
    transform: translateY(10px);
    opacity: 0;
    transition: all 0.4s 0.1s var(--cr-transition);
}

.cleanroom-window-slider .center .cleanroom-card .industry-icon {
    transform: translateY(0);
    opacity: 1;
}

.card-title {
    font-family: 'Martel', serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--cr-primary);
    margin: 0 0 10px 0;
    transform: translateY(10px);
    transition: transform 0.4s ease;
}

[data-theme="dark"] .card-title {
    color: var(--cr-accent);
}

.cleanroom-window-slider .center .cleanroom-card .card-title {
    transform: translateY(0);
}

.card-desc {
    font-size: 0.95rem;
    line-height: 1.5;
    color: #555;
    margin: 0;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s 0.1s ease;
}

[data-theme="dark"] .card-desc {
    color: #ccc;
}

.cleanroom-window-slider .center .cleanroom-card .card-desc {
    opacity: 1;
    transform: translateY(0);
}

/* CTA Button */
.card-cta {
    margin-top: 15px;
    align-self: flex-start;
    padding: 8px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--cr-primary);
    background: transparent;
    border: 2px solid var(--cr-primary);
    border-radius: 30px;
    transition: all 0.3s;
    opacity: 0;
    transform: translateY(10px);
}

[data-theme="dark"] .card-cta {
    color: #fff;
    border-color: #fff;
}

.cleanroom-window-slider .center .cleanroom-card .card-cta {
    opacity: 1;
    transform: translateY(0);
}

.card-cta:hover {
    background: var(--cr-primary);
    color: #fff;
    border-color: var(--cr-primary);
}

[data-theme="dark"] .card-cta:hover {
    background: var(--cr-accent);
    border-color: var(--cr-accent);
    color: #000;
}

/* 7. Controls Navigation */
.slider-nav-container {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    pointer-events: none;
    z-index: 20;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
}

.cleanroom-nav-btn {
    pointer-events: auto;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #fff;
    color: var(--cr-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] .cleanroom-nav-btn {
    background: #1e252b;
    color: var(--cr-accent);
    border-color: rgba(255, 255, 255, 0.1);
}

.cleanroom-nav-btn:hover {
    background: var(--cr-primary);
    color: #fff;
    transform: scale(1.1);
}

[data-theme="dark"] .cleanroom-nav-btn:hover {
    background: var(--cr-accent);
    color: #000;
}

/* 8. Responsive Adjustments */
@media (max-width: 991px) {
    .cleanroom-card {
        height: 450px;
    }
}

@media (max-width: 767px) {
    #industries-we-serve-section {
        padding: 60px 0;
    }

    #industries-we-serve-section .section-head h2 {
        font-size: 2rem;
    }

    .cleanroom-window-slider .owl-stage-outer {
        padding: 20px 0;
    }

    .cleanroom-card {
        height: 400px;
        transform: scale(0.95);
        opacity: 1;
        /* Keep visible on mobile */
        filter: none;
    }

    .cleanroom-window-slider .center .cleanroom-card {
        transform: scale(1);
    }

    .card-content {
        padding: 20px;
    }

    .industry-icon {
        width: 40px;
        height: 40px;
        font-size: 16px;
        top: -20px;
        right: 20px;
    }

    /* Force visibility of content on mobile if center trigger is fickle */
    .card-desc,
    .card-cta,
    .industry-icon {
        opacity: 1 !important;
        transform: none !important;
    }

    .slider-nav-container {
        display: none;
        /* Swipe only on mobile for cleaner look */
    }
}