Skip to content

Commit 4ac5c95

Browse files
Modification on design
1 parent 0a8a924 commit 4ac5c95

3 files changed

Lines changed: 85 additions & 11 deletions

File tree

app/globals.css

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ pre code {
166166
width: 10px;
167167
height: 10px;
168168
border-radius: 50%;
169-
background: #ffd945; /* Amarillo */
169+
background: #00F050; /* Verde */
170170
}
171171

172172
/* Skill tag styling */
@@ -182,14 +182,14 @@ pre code {
182182
}
183183

184184
.skill-tag:hover {
185-
border-color: #ffd945; /* Amarillo */
185+
border-color: #00F050; /* Verde */
186186
transform: translateY(-2px);
187187
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
188188
}
189189

190190
.skill-tag-icon {
191191
margin-right: 0.5rem;
192-
color: #ffd945; /* Amarillo */
192+
color: #00F050; /* Verde */
193193
}
194194

195195
/* Button hover fix */

components/hero-section.tsx

Lines changed: 81 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import { Button } from "@/components/ui/button"
88
export function HeroSection() {
99
const [isVisible, setIsVisible] = useState(false)
1010
const [currentLine, setCurrentLine] = useState(0)
11+
const [mousePosition, setMousePosition] = useState({ x: 0, y: 0 })
1112
const codeLines = [
1213
{
1314
id: 1,
@@ -59,25 +60,98 @@ export function HeroSection() {
5960
return () => clearTimeout(timer)
6061
}, [])
6162

63+
// Manejo del movimiento del mouse para el patrón topográfico
64+
useEffect(() => {
65+
const handleMouseMove = (e: MouseEvent) => {
66+
const rect = sectionRef.current?.getBoundingClientRect()
67+
if (rect) {
68+
setMousePosition({
69+
x: ((e.clientX - rect.left) / rect.width) * 100,
70+
y: ((e.clientY - rect.top) / rect.height) * 100,
71+
})
72+
}
73+
}
74+
75+
const section = sectionRef.current
76+
if (section) {
77+
section.addEventListener('mousemove', handleMouseMove)
78+
return () => section.removeEventListener('mousemove', handleMouseMove)
79+
}
80+
}, [])
81+
6282
return (
6383
<section
6484
id="home"
6585
ref={sectionRef}
6686
className="min-h-screen flex items-center py-20 relative overflow-hidden"
6787
style={{ position: "relative" }}
6888
>
69-
{/* Spotlights de color en los lados */}
89+
{/* Patrón topográfico animado */}
7090
<div
7191
aria-hidden="true"
7292
className="pointer-events-none absolute inset-0 z-0"
7393
style={{
74-
background:
75-
`radial-gradient(400px 200px at 0% 20%, rgba(255,217,69,0.18), transparent 70%),` +
76-
`radial-gradient(400px 200px at 100% 80%, rgba(255,217,69,0.22), transparent 70%)` +
77-
`,radial-gradient(300px 150px at 50% 100%, rgba(255,217,69,0.10), transparent 80%)`,
78-
transition: "background 0.5s",
94+
background: `
95+
radial-gradient(circle at ${mousePosition.x}% ${mousePosition.y}%,
96+
rgba(0,240,80,0.15) 0%,
97+
rgba(0,240,80,0.08) 25%,
98+
rgba(0,240,80,0.04) 50%,
99+
transparent 70%
100+
)
101+
`,
102+
transition: 'background 0.3s ease-out',
79103
}}
80-
/>
104+
>
105+
{/* Líneas topográficas */}
106+
<svg
107+
className="absolute inset-0 w-full h-full"
108+
style={{
109+
transform: `translate(${(mousePosition.x - 50) * 0.02}px, ${(mousePosition.y - 50) * 0.02}px)`,
110+
transition: 'transform 0.3s ease-out',
111+
}}
112+
>
113+
<defs>
114+
<pattern id="topographic" x="0" y="0" width="120" height="120" patternUnits="userSpaceOnUse">
115+
{/* Líneas topográficas concéntricas */}
116+
<circle cx="60" cy="60" r="10" fill="none" stroke="rgba(0,240,80,0.1)" strokeWidth="0.5"/>
117+
<circle cx="60" cy="60" r="20" fill="none" stroke="rgba(0,240,80,0.08)" strokeWidth="0.5"/>
118+
<circle cx="60" cy="60" r="30" fill="none" stroke="rgba(0,240,80,0.06)" strokeWidth="0.5"/>
119+
<circle cx="60" cy="60" r="40" fill="none" stroke="rgba(0,240,80,0.04)" strokeWidth="0.5"/>
120+
<circle cx="60" cy="60" r="50" fill="none" stroke="rgba(0,240,80,0.02)" strokeWidth="0.5"/>
121+
</pattern>
122+
</defs>
123+
<rect width="100%" height="100%" fill="url(#topographic)" />
124+
</svg>
125+
126+
{/* Líneas adicionales que siguen el cursor */}
127+
<div
128+
className="absolute w-96 h-96 rounded-full border border-dark-accent/10"
129+
style={{
130+
left: `${mousePosition.x}%`,
131+
top: `${mousePosition.y}%`,
132+
transform: 'translate(-50%, -50%)',
133+
transition: 'all 0.3s ease-out',
134+
}}
135+
/>
136+
<div
137+
className="absolute w-64 h-64 rounded-full border border-dark-accent/15"
138+
style={{
139+
left: `${mousePosition.x}%`,
140+
top: `${mousePosition.y}%`,
141+
transform: 'translate(-50%, -50%)',
142+
transition: 'all 0.4s ease-out',
143+
}}
144+
/>
145+
<div
146+
className="absolute w-32 h-32 rounded-full border border-dark-accent/20"
147+
style={{
148+
left: `${mousePosition.x}%`,
149+
top: `${mousePosition.y}%`,
150+
transform: 'translate(-50%, -50%)',
151+
transition: 'all 0.5s ease-out',
152+
}}
153+
/>
154+
</div>
81155
<div className="container px-4 md:px-6 relative z-10">
82156
<div className="grid gap-8 lg:grid-cols-[1fr_400px] lg:gap-12 xl:grid-cols-[1fr_500px]">
83157
<div className="flex flex-col justify-center space-y-8">

tailwind.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const config: Config = {
2525
muted: "#404040",
2626
foreground: "#F5F5F5",
2727
secondary: "#A0A0A0",
28-
accent: "#FFD945",
28+
accent: "#00F050" /*"#FFD945"*/,
2929
code: {
3030
bg: "#121212",
3131
comment: "#6A9955",

0 commit comments

Comments
 (0)