From 9ef05f8eeaa6436a50df37f0285e6da568b7edc9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mauricio=20L=C3=B3pez=20Coria?= Date: Wed, 1 Jul 2026 23:52:37 -0300 Subject: [PATCH] fix: DifferenceCards grid uniforme 3 columnas iguales MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Sacar bento grid asimétrico (hero card col-span-2) - Todas las cards mismo tamaño, padding y tipografía - Eliminar 'Equipo de 3 ingenieros SRE' y avatares - Renombrar clases bento-* → diff-* --- src/components/DifferenceCards.astro | 83 +++++----------------------- 1 file changed, 15 insertions(+), 68 deletions(-) diff --git a/src/components/DifferenceCards.astro b/src/components/DifferenceCards.astro index 7e12c8b..8a43ba7 100644 --- a/src/components/DifferenceCards.astro +++ b/src/components/DifferenceCards.astro @@ -1,6 +1,5 @@ --- -// "Por qué elegirnos" — Bento grid with glass cards + magnetic hover glow -// Phase 3 — Organic Fluidity Premium +// "Por qué elegirnos" — Uniform 3-column grid with glass cards import SectionEyebrow from './SectionEyebrow.astro'; import type { TranslationKey } from '@/i18n/ui'; import MateIcon from './icons/MateIcon.astro'; @@ -12,16 +11,8 @@ interface Props { } const { t } = Astro.props; -interface DiffItem { - Icon?: typeof MateIcon; - titleKey: TranslationKey; - bodyKey: TranslationKey; - hero?: boolean; - area?: string; -} - -const items: DiffItem[] = [ - { Icon: MateIcon, titleKey: 'diff.support.title' as TranslationKey, bodyKey: 'diff.support.body' as TranslationKey, hero: true }, +const items = [ + { Icon: MateIcon, titleKey: 'diff.support.title' as TranslationKey, bodyKey: 'diff.support.body' as TranslationKey }, { Icon: SovereigntyIcon, titleKey: 'diff.sovereignty.title' as TranslationKey, bodyKey: 'diff.sovereignty.body' as TranslationKey }, { Icon: GlobeIcon, titleKey: 'diff.infra.title' as TranslationKey, bodyKey: 'diff.infra.body' as TranslationKey }, ]; @@ -38,49 +29,18 @@ const items: DiffItem[] = [

- -
+
{items.map((item, i) => ( -
+
- {item.Icon && } +
-

+

{t(item.titleKey)}

-

+

{t(item.bodyKey)}

- - {item.hero && ( -
-
-
M
-
+2
-
- - {t('diff.eyebrow') === 'La diferencia' ? 'Equipo de 3 ingenieros SRE' : 'Team of 3 SRE engineers'} - -
- )}
))}
@@ -93,8 +53,7 @@ const items: DiffItem[] = [ gsap.registerPlugin(ScrollTrigger); - // Mouse-tracking glow on glass cards - document.querySelectorAll('.bento-item').forEach((card) => { + document.querySelectorAll('.diff-card').forEach((card) => { card.addEventListener('mousemove', (e) => { const rect = (e.currentTarget as HTMLElement).getBoundingClientRect(); const x = ((e.clientX - rect.left) / rect.width) * 100; @@ -104,12 +63,11 @@ const items: DiffItem[] = [ }); }); - // ScrollTrigger stagger reveal const prefersReduced = window.matchMedia('(prefers-reduced-motion: reduce)').matches; if (!prefersReduced) { - gsap.from('.bento-item', { + gsap.from('.diff-card', { scrollTrigger: { - trigger: '.bento-grid', + trigger: '.diff-grid', start: 'top 80%', toggleActions: 'play none none none', }, @@ -123,31 +81,20 @@ const items: DiffItem[] = [