﻿*, *::before, *::after { box-sizing: border-box; }

  .idx-edu {
    position: relative;
    padding: 6rem 1.5rem;
    overflow: hidden;
    background-color: #09090b;
    font-family: 'Inter', sans-serif;
  }

  /* Dot-grid texture */
  .idx-edu::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle at 2px 2px, rgba(220,38,38,0.15) 1px, transparent 0);
    background-size: 40px 40px;
    opacity: 0.2;
    z-index: 0;
  }

  /* Subtle corner red gradient */
  .idx-edu::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(239,68,68,0.06) 0%, transparent 50%, rgba(220,38,38,0.06) 100%);
    z-index: 0;
  }

  .idx-edu-inner {
    position: relative;
    z-index: 10;
    max-width: 72rem;
    margin: 0 auto;
  }

  /* Section header */
  .idx-edu-header {
    text-align: center;
    margin-bottom: 4rem;
  }

  .idx-edu-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    background: rgba(239,68,68,0.1);
    border: 1px solid rgba(239,68,68,0.3);
    margin-bottom: 1.5rem;
  }

  .idx-edu-badge-icon { width: 1rem; height: 1rem; color: #ef4444; }

  .idx-edu-badge-text {
    font-size: 0.75rem;
    font-weight: 600;
    color: #ef4444;
    text-transform: uppercase;
    letter-spacing: 0.08em;
  }

  .idx-edu-h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.03em;
    margin: 0 0 1rem;
  }

  .idx-edu-sub {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.7);
    max-width: 40rem;
    margin: 0 auto;
    letter-spacing: -0.01em;
  }

  /* Products grid */
  .idx-edu-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 4rem;
  }

  @media (min-width: 768px) { .idx-edu-grid { grid-template-columns: 1fr 1fr; } }
  @media (min-width: 1024px) { .idx-edu-grid { grid-template-columns: repeat(3, 1fr); } }

  .idx-edu-card {
    position: relative;
    background: rgba(24,24,27,0.6);
    backdrop-filter: blur(12px);
    border-radius: 0.75rem;
    border: 1px solid rgba(220,38,38,0.2);
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.175,0.885,0.32,1.275);
  }
  .idx-edu-card:hover {
    border-color: rgba(220,38,38,0.4);
    transform: translateY(-0.5rem);
    box-shadow: 0 0 30px -5px rgba(220,38,38,0.3);
  }

  .idx-edu-img-wrap {
    position: relative;
    aspect-ratio: 1 / 1;
    padding: 2rem;
    background: linear-gradient(135deg, rgba(20,20,22,0.8), rgba(0,0,0,0.7));
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
  }

  .idx-edu-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.5s cubic-bezier(0.175,0.885,0.32,1.275);
  }
  .idx-edu-card:hover .idx-edu-img { transform: scale(1.05); }

  .idx-edu-img-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(239,68,68,0.12), transparent, transparent);
    opacity: 0;
    transition: opacity 0.5s;
  }
  .idx-edu-card:hover .idx-edu-img-overlay { opacity: 1; }

  .idx-edu-card-body {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }

  .idx-edu-prod-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.02em;
    margin: 0;
  }

  .idx-edu-prod-sub {
    font-size: 0.8rem;
    font-weight: 500;
    color: #ef4444;
    letter-spacing: -0.01em;
    margin-top: 0.25rem;
  }

  .idx-edu-prod-desc {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.65);
    line-height: 1.6;
    margin: 0;
  }

  .idx-edu-takeaway {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 0.5rem;
    background: rgba(239,68,68,0.06);
    border: 1px solid rgba(239,68,68,0.12);
  }

  .idx-edu-takeaway-icon {
    width: 1rem;
    height: 1rem;
    color: #ef4444;
    flex-shrink: 0;
    margin-top: 1px;
  }

  .idx-edu-takeaway-text {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.6);
    line-height: 1.5;
    margin: 0;
  }

  .idx-edu-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #ef4444;
    text-decoration: none;
    letter-spacing: -0.01em;
    transition: color 0.3s;
  }
  .idx-edu-link:hover { color: #f87171; }

  .idx-edu-link-arrow { width: 1rem; height: 1rem; transition: transform 0.3s; }
  .idx-edu-link:hover .idx-edu-link-arrow { transform: translateX(4px); }

  /* CTA row — AnimatedButton (matches hero "Start Your Transformation") */
  .idx-edu-cta { text-align: center; }

  .idx-edu-cta-text {
    font-size: 1.05rem;
    color: rgba(255,255,255,0.7);
    margin: 0 0 1.5rem;
  }

  @keyframes idx-edu-anim-transform {
    0%   { transform: translate(-55%); }
    100% { transform: translate(55%); }
  }
  @keyframes idx-edu-anim-opacity {
    0%, 100% { opacity: 0; }
    15%       { opacity: 1; }
    65%       { opacity: 0; }
  }

  .idx-edu-anim-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    height: 60px;
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    border: 1px solid rgba(255,255,255,0.1);
    background: linear-gradient(135deg, rgb(26,26,26) 0%, rgb(10,10,10) 100%);
    box-shadow:
      0 8px 32px rgba(0,0,0,0.4),
      inset 0 1px 0 rgba(255,255,255,0.1),
      inset 0 -1px 0 rgba(0,0,0,0.5),
      0 0 20px rgba(244,63,94,0.1);
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.4s cubic-bezier(0.4,0,0.2,1),
                box-shadow 0.4s cubic-bezier(0.4,0,0.2,1);
  }
  .idx-edu-anim-btn:hover {
    transform: translateY(-2px);
    box-shadow:
      0 12px 40px rgba(0,0,0,0.5),
      inset 0 1px 0 rgba(255,255,255,0.15),
      inset 0 -1px 0 rgba(0,0,0,0.6),
      0 0 30px rgba(244,63,94,0.2);
  }

  .idx-edu-anim-loader {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 1;
    background: transparent;
    -webkit-mask: repeating-linear-gradient(
      90deg,
      transparent 0, transparent 6px,
      black 7px, black 8px
    );
    mask: repeating-linear-gradient(
      90deg,
      transparent 0, transparent 6px,
      black 7px, black 8px
    );
  }

  .idx-edu-anim-glow {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-image:
      radial-gradient(circle at 50% 50%, #f43f5e 0%, transparent 50%),
      radial-gradient(circle at 45% 45%, #f43f5e 0%, transparent 45%),
      radial-gradient(circle at 55% 55%, rgba(244,63,94,0.53) 0%, transparent 45%),
      radial-gradient(circle at 45% 55%, rgba(244,63,94,0.67) 0%, transparent 45%),
      radial-gradient(circle at 55% 45%, rgba(244,63,94,0.80) 0%, transparent 45%);
    -webkit-mask: radial-gradient(circle at 50% 50%, transparent 0%, transparent 10%, black 25%);
    mask: radial-gradient(circle at 50% 50%, transparent 0%, transparent 10%, black 25%);
    animation: idx-edu-anim-transform 2s infinite alternate,
               idx-edu-anim-opacity   4s infinite;
    animation-timing-function: cubic-bezier(0.6,0.8,0.5,1);
    filter: drop-shadow(0 0 8px rgba(244,63,94,0.6));
  }

  .idx-edu-anim-text {
    position: relative;
    z-index: 2;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    user-select: none;
    color: #fff;
    text-shadow:
      0 0 12px rgba(244,63,94,0.27),
      0 0 4px  rgba(244,63,94,0.13);
    white-space: nowrap;
    letter-spacing: -0.01em;
  }

  .idx-edu-divider {
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(220,38,38,0.3), transparent);
    margin-top: 4rem;
  }

  @media (max-width: 600px) { .idx-edu { padding: 4rem 1rem; } }