/* ==========================================================================
   RESOURCES & PRODUCT CATALOGS PAGE STYLES (Automation & Security Inc.)
   100% Full-Width Fluid & Fully Responsive Design Across All Viewports
   ========================================================================== */

:root {
  --primary-red: #e11d2a;
  --primary-red-hover: #c8101e;
  --primary-red-tint: #fee2e2;
  --primary-red-tint-soft: #fef2f2;

  --navy-950: #060e1f;
  --navy-900: #091a3e;
  --navy-800: #102a5c;
  --navy-700: #173b7e;

  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-400: #94a3b8;
  --slate-300: #cbd5e1;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --slate-50:  #f8fafc;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

/* Full Width Fluid Container */
.resources-container {
  width: 100%;
  max-width: 100% !important;
  margin: 0 auto;
  padding-left: clamp(20px, 3.8vw, 64px);
  padding-right: clamp(20px, 3.8vw, 64px);
  box-sizing: border-box;
}

/* ==========================================================================
   1. HERO SECTION (Full Width Edge-to-Edge Background)
   ========================================================================== */
.resources-hero-section {
  position: relative;
  width: 100%;
  height: 436px;
  min-height: 436px;
  background-color: #f8fafc;
  background-image: url('/images/resources/resources-hero-bg.png');
  background-repeat: no-repeat;
  background-position: right center;
  background-size: cover;
  display: flex;
  align-items: flex-start;
  overflow: hidden;
  padding: 48px 0 0 0;
  border-bottom: 1px solid #e2e8f0;
  box-sizing: border-box;
}

.resources-hero-inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(24px, 3.5vw, 48px);
  width: 100%;
  padding-top: 0;
  padding-bottom: 0;
}

.resources-hero-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  max-width: min(680px, 58vw);
}

/* Breadcrumb (Matches About Us & Solutions Pill Badge Style) */
.resources-breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: #64748b;
  margin-bottom: 10px;
  background: rgba(255, 255, 255, 0.88);
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid rgba(226, 232, 240, 0.88);
  box-shadow: none;
  width: fit-content;
}

.resources-breadcrumb .breadcrumb-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #334155;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.resources-breadcrumb .breadcrumb-link:hover {
  color: var(--primary-red);
}

.resources-breadcrumb .breadcrumb-icon {
  color: var(--primary-red);
  flex-shrink: 0;
}

.resources-breadcrumb .breadcrumb-sep {
  color: #cbd5e1;
  font-size: 11px;
}

.resources-breadcrumb .breadcrumb-current {
  color: var(--primary-red);
  font-weight: 600;
}

/* Mini Tag */
.hero-tag-wrap,
.resources-mini-tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  max-width: 100%;
}

.hero-tag-bar {
  display: none !important;
}

.hero-tag-text {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 1.2px;
  color: var(--primary-red);
  text-transform: uppercase;
  line-height: 1.3;
}

/* Hero Title */
.resources-hero-title {
  font-size: clamp(28px, 2.7vw, 40px);
  font-weight: 900;
  line-height: 1.15;
  color: var(--navy-900);
  letter-spacing: -0.8px;
  margin-bottom: 10px;
}

.resources-hero-title .highlight-red {
  color: var(--primary-red);
}

/* Hero Subtitle */
.resources-hero-desc {
  font-size: clamp(14px, 1.05vw, 15px);
  line-height: 1.55;
  color: var(--slate-600);
  max-width: 600px;
  margin: 0;
}

/* Hero Action Buttons */
.resources-hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.btn-hero-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--primary-red);
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 700;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(225, 29, 42, 0.25);
}

.btn-hero-primary:hover {
  background: var(--primary-red-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(225, 29, 42, 0.35);
  color: #ffffff;
}

.btn-hero-primary .btn-arrow {
  transition: transform 0.2s ease;
}

.btn-hero-primary:hover .btn-arrow {
  transform: translateY(2px);
}

.btn-hero-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--slate-700);
  font-size: 13.5px;
  font-weight: 600;
  border-radius: 8px;
  border: 1px solid var(--slate-300);
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-hero-secondary:hover {
  background: #ffffff;
  color: var(--primary-red);
  border-color: var(--primary-red);
  transform: translateY(-2px);
}

.btn-hero-secondary .btn-arrow {
  transition: transform 0.2s ease;
}

.btn-hero-secondary:hover .btn-arrow {
  transform: translateX(3px);
}

/* Feature Strip Below Buttons */
.resources-hero-features {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-feat-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--slate-700);
}

.hero-feat-chip .chip-icon {
  color: #10b981;
  flex-shrink: 0;
}

/* Right Hero Card: Sidebar */
.resources-hero-sidebar {
  flex-shrink: 0;
  width: min(340px, 35vw);
}

.resources-hero-cta-card {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 14px;
  padding: 22px 24px;
  box-shadow: none;
}

.hero-cta-card-header {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 8px;
}

.cta-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--primary-red);
  display: inline-block;
}

.cta-card-tag {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.8px;
  color: var(--slate-500);
  text-transform: uppercase;
}

.resources-hero-cta-title {
  font-size: 17px;
  font-weight: 800;
  color: var(--navy-900);
  margin-bottom: 6px;
}

.resources-hero-cta-desc {
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--slate-600);
  margin-bottom: 14px;
}

.btn-hero-talk {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 10px 16px;
  background: var(--primary-red);
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.btn-hero-talk:hover {
  background: var(--primary-red-hover);
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-hero-talk .arrow {
  transition: transform 0.2s ease;
}

.btn-hero-talk:hover .arrow {
  transform: translateX(4px);
}

.cta-card-footer-info {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  font-size: 11px;
  font-weight: 500;
  color: var(--slate-500);
}

.cta-card-footer-info svg {
  color: var(--slate-400);
  flex-shrink: 0;
}

/* ==========================================================================
   2. CATALOGS SECTION
   ========================================================================== */
.resources-catalogs-section {
  width: 100%;
  padding-top: clamp(20px, 2.2vw, 32px);
  padding-bottom: clamp(36px, 4vw, 60px);
  background-color: #ffffff;
}

.resources-section-header {
  margin-bottom: clamp(12px, 1.4vw, 18px);
}

.resources-section-title {
  font-size: clamp(24px, 2.5vw, 34px);
  font-weight: 900;
  color: var(--navy-900);
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}

.resources-section-subtitle {
  font-size: clamp(14px, 1.05vw, 16px);
  color: var(--slate-500);
  margin: 0;
}

/* Search Bar Wrap */
.resources-search-wrap {
  margin-bottom: clamp(16px, 1.8vw, 24px);
}

.resources-search-bar {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 640px;
  background: #ffffff;
  border: 1px solid var(--slate-200);
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
  transition: all 0.2s ease;
}

.resources-search-bar:focus-within {
  border-color: var(--primary-red);
  box-shadow: 0 0 0 3px rgba(225, 29, 42, 0.12);
}

.resources-search-bar .search-icon {
  width: 20px;
  height: 20px;
  color: var(--slate-400);
  margin-left: 16px;
  flex-shrink: 0;
}

.resources-search-bar .search-input {
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  padding: 13px 16px;
  font-size: 14.5px;
  color: var(--slate-900);
  font-family: inherit;
}

.resources-search-bar .search-input::placeholder {
  color: var(--slate-400);
}

.resources-search-bar .search-clear-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--slate-100);
  color: var(--slate-600);
  border: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  margin-right: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.resources-search-bar .search-clear-btn:hover {
  background: var(--slate-200);
  color: var(--slate-900);
}

.search-meta-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
  font-size: 13px;
  color: var(--slate-500);
}

.search-results-count {
  font-weight: 500;
}

.active-filter-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--primary-red-tint);
  color: var(--primary-red);
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 14px;
}

.clear-badge-btn {
  background: none;
  border: none;
  color: var(--primary-red);
  font-size: 14px;
  line-height: 1;
  padding: 0;
  cursor: pointer;
}

/* 12 Catalog Cards Grid (Full width fluid) */
.resources-catalogs-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: clamp(14px, 1.4vw, 20px);
  width: 100%;
}

/* Responsive grid breaks */
@media (max-width: 1199px) {
  .resources-catalogs-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
  }
}

@media (max-width: 900px) {
  .resources-catalogs-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
}

@media (max-width: 680px) {
  .resources-catalogs-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }
}

@media (max-width: 420px) {
  .resources-catalogs-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
}

/* Individual Catalog Card */
.catalog-card {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 1px solid var(--slate-200);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}

.catalog-card:hover {
  transform: translateY(-5px);
  border-color: #cbd5e1;
  box-shadow: 0 12px 24px -6px rgba(15, 23, 42, 0.08), 0 4px 8px -2px rgba(15, 23, 42, 0.03);
}

/* Brand Logo Header - Centered */
.catalog-card-header {
  padding: 14px 16px 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 52px;
  background: #ffffff;
}

.catalog-brand-logo {
  max-height: 28px;
  max-width: 120px;
  width: auto;
  height: auto;
  margin: 0 auto;
  display: block;
  object-fit: contain;
  filter: contrast(1.05);
}

/* Image Cover - Full Width & Height Flush */
.catalog-card-image-wrap {
  width: 100%;
  height: clamp(220px, 16vw, 275px);
  background-color: #f8fafc;
  overflow: hidden;
  display: block;
  padding: 0;
  box-sizing: border-box;
  border-top: 1px solid var(--slate-100);
  border-bottom: 1px solid var(--slate-100);
}

.catalog-card-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center top;
  transition: transform 0.35s ease;
}

.catalog-card:hover .catalog-card-image {
  transform: scale(1.04);
}

/* Card Body */
.catalog-card-body {
  padding: 12px 16px 8px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.catalog-brand-name {
  font-size: 14.5px;
  font-weight: 800;
  color: var(--navy-900);
  margin-bottom: 2px;
  letter-spacing: -0.2px;
}

.catalog-card-sub {
  font-size: 13px;
  font-weight: 500;
  color: var(--slate-600);
  margin-bottom: 2px;
}

.catalog-card-year {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--slate-400);
  margin: 0;
}

/* Card Footer */
.catalog-card-footer {
  padding: 10px 16px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #f1f5f9;
}

.catalog-file-info {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 600;
  color: var(--slate-600);
}

.pdf-icon-badge {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
}

.catalog-view-btn,
.catalog-download-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  height: 30px;
  border-radius: 6px;
  background: var(--slate-100);
  color: var(--slate-700);
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--slate-200);
  transition: all 0.2s ease;
  text-decoration: none;
  cursor: pointer;
}

.catalog-view-btn svg,
.catalog-download-link svg {
  width: 15px;
  height: 15px;
  stroke-width: 2;
  flex-shrink: 0;
}

.catalog-card:hover .catalog-view-btn,
.catalog-view-btn:hover,
.catalog-card:hover .catalog-download-link,
.catalog-download-link:hover {
  background: var(--primary-red);
  color: #ffffff;
  border-color: var(--primary-red);
}

/* Empty State */
.catalogs-empty-state {
  text-align: center;
  padding: 60px 20px;
  background: var(--slate-50);
  border: 1px dashed var(--slate-300);
  border-radius: 12px;
  margin-top: 20px;
}

.empty-icon-wrap {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--slate-200);
  color: var(--slate-500);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.empty-icon-wrap svg {
  width: 30px;
  height: 30px;
}

.empty-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--navy-900);
  margin-bottom: 8px;
}

.empty-text {
  font-size: 14.5px;
  color: var(--slate-600);
  max-width: 480px;
  margin: 0 auto 20px;
}

.btn-reset-search {
  display: inline-flex;
  align-items: center;
  padding: 10px 20px;
  background: var(--primary-red);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: 13.5px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.btn-reset-search:hover {
  background: var(--primary-red-hover);
}

/* ==========================================================================
   3. BROWSE BY BRAND SECTION
   ========================================================================== */
.resources-brands-section {
  width: 100%;
  padding-top: clamp(48px, 5.5vw, 80px);
  padding-bottom: clamp(48px, 5.5vw, 80px);
  background-color: #f8fafc;
  border-top: 1px solid var(--slate-200);
}

.resources-brands-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: clamp(12px, 1.4vw, 20px);
  width: 100%;
}

@media (max-width: 1200px) {
  .resources-brands-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 768px) {
  .resources-brands-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
}

@media (max-width: 480px) {
  .resources-brands-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}

/* Brand Filter Card */
.brand-filter-card {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border: 1px solid var(--slate-200);
  border-radius: 10px;
  padding: clamp(14px, 1.8vw, 22px);
  height: clamp(68px, 6vw, 88px);
  cursor: pointer;
  transition: all 0.2s ease;
  outline: none;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.02);
}

.brand-filter-card img {
  max-width: 85%;
  max-height: clamp(28px, 3vw, 42px);
  width: auto;
  height: auto;
  object-fit: contain;
  transition: transform 0.2s ease;
}

.brand-filter-card:hover {
  border-color: var(--primary-red);
  box-shadow: 0 6px 16px rgba(225, 29, 42, 0.08);
  transform: translateY(-2px);
}

.brand-filter-card:hover img {
  transform: scale(1.05);
}

.brand-filter-card.active {
  border-color: var(--primary-red);
  background: #fffafa;
  box-shadow: 0 0 0 2px var(--primary-red);
}

/* ==========================================================================
   4. HELP / CTA BANNER SECTION
   ========================================================================== */
.resources-cta-section {
  width: 100%;
  padding-top: clamp(24px, 3.5vw, 48px);
  padding-bottom: clamp(48px, 6vw, 88px);
  background-color: #f8fafc;
}

.resources-cta-card {
  position: relative;
  width: 100%;
  min-height: clamp(260px, 22vw, 320px);
  background-color: #091830;
  background-image: url('/images/cta-banner-technician.png');
  background-repeat: no-repeat;
  background-position: right center;
  background-size: cover;
  border-radius: clamp(14px, 1.6vw, 20px);
  overflow: hidden;
  display: flex;
  align-items: center;
  box-shadow: 0 16px 36px -10px rgba(6, 14, 31, 0.25);
}

.resources-cta-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(6, 14, 31, 0.94) 0%,
    rgba(9, 26, 62, 0.86) 48%,
    rgba(9, 26, 62, 0.35) 72%,
    rgba(9, 26, 62, 0.10) 100%
  );
  z-index: 1;
}

.resources-cta-content {
  position: relative;
  z-index: 2;
  padding: clamp(32px, 4.5vw, 56px);
  max-width: min(540px, 56%);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.resources-cta-badge {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 700;
  color: #f87171;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 12px;
}

.resources-cta-title {
  font-size: clamp(24px, 2.8vw, 40px);
  font-weight: 900;
  line-height: 1.2;
  color: #ffffff;
  letter-spacing: -0.6px;
  margin-bottom: 14px;
}

.resources-cta-subtitle {
  font-size: clamp(14px, 1.1vw, 16.5px);
  line-height: 1.55;
  color: #cbd5e1;
  margin-bottom: 24px;
  max-width: 540px;
}

.btn-cta-quote {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: clamp(12px, 1.2vw, 15px) clamp(24px, 2vw, 32px);
  background: var(--primary-red);
  color: #ffffff;
  font-size: clamp(13.5px, 1vw, 15px);
  font-weight: 700;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.25s ease;
  box-shadow: 0 4px 14px rgba(225, 29, 42, 0.35);
}

.btn-cta-quote:hover {
  background: var(--primary-red-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(225, 29, 42, 0.45);
  color: #ffffff;
}

.btn-cta-quote .arrow {
  transition: transform 0.2s ease;
}

.btn-cta-quote:hover .arrow {
  transform: translateX(4px);
}

/* ==========================================================================
   MOBILE & TABLET ADAPTATIONS
   ========================================================================== */
@media (max-width: 1100px) {
  .resources-hero-section {
    background-position: left center;
  }
}

@media (max-width: 992px) {
  .resources-hero-section {
    height: auto;
    min-height: auto;
    padding: 36px 0;
  }

  .resources-hero-inner {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .resources-hero-content {
    max-width: 100%;
  }

  .resources-hero-sidebar {
    width: 100%;
    max-width: 480px;
    margin-top: 14px;
  }
}

@media (max-width: 768px) {
  .resources-hero-content {
    max-width: 100%;
  }

  .resources-cta-content {
    max-width: 100%;
    padding: 36px 24px;
  }

  .resources-cta-overlay {
    background: linear-gradient(
      180deg,
      rgba(6, 14, 31, 0.95) 0%,
      rgba(9, 26, 62, 0.88) 100%
    );
  }
}
