/* ========================================
   SECM PRODUCT GRID MODULE
   Featured Base SECM + Options Grid
   ======================================== */

/* ========================================
   SECTION CONTAINER
   ======================================== */

.sx-sdc-product-grid {
  --brand: var(--color-brand-blue);
  background: var(--color-bg-light-gray);
  padding: var(--space-section) 0;
}

/* Anchor offset for sticky header */
#sx-sdc-product-grid {
  scroll-margin-top: 140px;
}

.sx-sdc-grid-container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* ========================================
   SECTION HEADER
   ======================================== */

.sx-sdc-grid-section-header {
  text-align: center;
  margin-bottom: 60px;
}

.sx-sdc-grid-section-header .sx-title {
  text-align: center;
  margin-bottom: 15px;
}

.sx-sdc-grid-section-header .sx-lead {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

/* ========================================
   FEATURED PRODUCT (BASE SECM)
   ======================================== */

.sx-sdc-product-featured {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  background: var(--color-white);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-md);
  padding: 40px;
  margin-bottom: 60px;
  align-items: center;
  transition: all 0.3s ease;
}

.sx-sdc-product-featured:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

/* Featured Image */
.sx-sdc-product-featured-image {
  position: relative;
  overflow: hidden;
  border-radius: var(--border-radius);
}

.sx-sdc-product-featured-img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--border-radius);
  transform-origin: 62% 48%;
  transition: transform 0.6s ease, opacity 0.35s ease;
}

.sx-sdc-product-featured-img-hover {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.sx-sdc-product-featured:hover .sx-sdc-product-featured-img {
  transform: scale(1.1);
}

.sx-sdc-product-featured:hover .sx-sdc-product-featured-img-base {
  opacity: 0;
}

.sx-sdc-product-featured:hover .sx-sdc-product-featured-img-hover {
  opacity: 1;
}

/* "Starting Point" Badge */
.sx-sdc-badge-featured {
  position: absolute;
  top: 15px;
  left: 15px;
  background: var(--color-brand-blue);
  color: var(--color-white);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: var(--font-size-small);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Featured Content */
.sx-sdc-product-featured-content h3 {
  font-family: var(--font-headings);
  font-size: var(--font-size-h3);
  color: var(--color-brand-gray);
  margin: 0 0 20px 0;
  font-weight: 700;
}

.sx-sdc-product-description {
  font-family: var(--font-primary);
  font-size: var(--font-size-body);
  line-height: 1.6;
  color: var(--color-text);
  margin-bottom: 20px;
}

/* Product Highlights List */
.sx-sdc-product-highlights {
  list-style: none;
  padding: 0;
  margin: 0 0 25px 0;
}

.sx-sdc-product-highlights li {
  font-size: var(--font-size-body);
  color: var(--color-text);
  padding-left: 25px;
  margin-bottom: 10px;
  position: relative;
}

.sx-sdc-product-highlights li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--color-brand-blue);
  font-weight: bold;
  font-size: 1.2rem;
}

/* ========================================
   OPTIONS GRID
   ======================================== */

.sx-sdc-options-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 30px;
}

.sx-sdc-options-grid > .sx-sdc-product-card {
  grid-column: auto;
}

/* Safety against shared class collisions from other modules */
.sx-sdc-product-grid .sx-sdc-options-grid {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  gap: 30px !important;
}

.sx-sdc-product-grid .sx-sdc-options-grid > .sx-sdc-product-card {
  width: 100%;
  min-width: 0;
}

.sx-sdc-product-grid .sx-sdc-product-card-image,
.sx-sdc-product-grid .sx-sdc-product-card-content {
  min-width: 0;
}

.sx-sdc-product-grid .sx-sdc-product-card-img {
  display: block;
  width: 100% !important;
}

/* ========================================
   PRODUCT CARD (OPTIONS)
   ======================================== */

.sx-sdc-product-card {
  background: var(--color-white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.sx-sdc-product-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

/* Card Image */
.sx-sdc-product-card-image {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.sx-sdc-product-card-img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transform-origin: 62% 48%;
  transition: transform 0.6s ease, opacity 0.35s ease;
}

.sx-sdc-product-card-img-hover {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.sx-sdc-product-card:hover .sx-sdc-product-card-img {
  transform: scale(1.1);
}

.sx-sdc-product-card:hover .sx-sdc-product-card-img-base {
  opacity: 0;
}

.sx-sdc-product-card:hover .sx-sdc-product-card-img-hover {
  opacity: 1;
}

/* Card Content */
.sx-sdc-product-card-content {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.sx-sdc-product-card-content h4 {
  font-family: var(--font-headings);
  font-size: var(--font-size-h4);
  color: var(--color-brand-gray);
  margin: 0 0 15px 0;
  font-weight: 600;
}

.sx-sdc-product-card-content p {
  font-size: var(--font-size-body);
  line-height: 1.6;
  color: var(--color-text);
  margin-bottom: 20px;
  flex-grow: 1;
}

/* Arrow Link */
.sx-sdc-link-arrow {
  color: var(--color-brand-blue);
  text-decoration: none;
  font-weight: 600;
  font-size: var(--font-size-body);
  display: inline-flex;
  align-items: center;
  transition: all 0.2s ease;
}

.sx-sdc-link-arrow:hover {
  color: var(--color-brand-blue-dark);
  transform: translateX(5px);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

/* Tablets (≤1024px) */
@media (max-width: 1024px) {
  .sx-sdc-options-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
  }

  .sx-sdc-options-grid > .sx-sdc-product-card {
    grid-column: auto;
  }
}

/* Mobile Landscape & Small Tablets (≤768px) */
@media (max-width: 768px) {
  .sx-sdc-product-grid {
    padding: var(--space-section-sm) 0;
  }

  .sx-sdc-grid-section-header {
    margin-bottom: 40px;
  }

  /* Featured Product: Stack vertically */
  .sx-sdc-product-featured {
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 30px;
    margin-bottom: 40px;
  }

  /* Options Grid: 1 column */
  .sx-sdc-options-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .sx-sdc-product-grid .sx-sdc-options-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }
}

/* Mobile Portrait (≤480px) */
@media (max-width: 480px) {
  .sx-sdc-grid-container {
    padding: 0 15px;
  }

  .sx-sdc-product-featured {
    padding: 20px;
  }

  .sx-sdc-product-card-content {
    padding: 20px;
  }

  .sx-sdc-grid-section-header .sx-title {
    font-size: 2rem;
  }

  .sx-sdc-grid-section-header .sx-lead {
    font-size: 1.1rem;
  }
}