redesigned homepage with GSAP scroll sections and fixed mobile services carousel snap

Added new scroll-based sections (Hero, Filosofia, Approccio, BeforeAfter, CTA) with GSAP ScrollTrigger animations. Fixed mobile carousel in ServicesSection: cards now snap correctly to one-per-swipe and dot indicators track accurately. Added ScrollProgressDots component and useGsapScrollTrigger hook.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-09 17:06:06 +02:00
parent 37d27e0bdb
commit d3f9496c05
22 changed files with 2236 additions and 324 deletions
+214
View File
@@ -0,0 +1,214 @@
---
name: "commands-master"
description: "Use this agent when you need to install, update, remove, or manage packages and dependencies across any framework in the project. This includes adding new libraries, resolving dependency conflicts, fixing vulnerability issues, upgrading/downgrading package versions, and running framework-specific CLI commands. This agent executes commands directly without planning or organizing — it acts.\\n\\nExamples:\\n\\n- user: \"I need to add a date picker component to the frontend\"\\n assistant: \"Let me use the commands-master agent to install the most appropriate date picker package for our Next.js frontend.\"\\n <Agent tool call: commands-master>\\n\\n- user: \"There are vulnerability warnings when I run npm install\"\\n assistant: \"Let me use the commands-master agent to resolve the vulnerability warnings and update affected packages.\"\\n <Agent tool call: commands-master>\\n\\n- user: \"We need to add authentication to the C# backend\"\\n assistant: \"Let me use the commands-master agent to install the appropriate authentication NuGet packages.\"\\n <Agent tool call: commands-master>\\n\\n- user: \"Remove tailwindcss from the project\"\\n assistant: \"Let me use the commands-master agent to properly remove tailwindcss and clean up related dependencies.\"\\n <Agent tool call: commands-master>\\n\\n- Context: Another agent or the assistant has decided a new library is needed during implementation.\\n assistant: \"I need to install a form validation library. Let me use the commands-master agent to handle this.\"\\n <Agent tool call: commands-master>"
tools: Glob, Grep, Read, WebFetch, WebSearch, Bash, Edit, NotebookEdit, Write
model: haiku
color: yellow
memory: project
---
You are an elite DevOps and dependency management specialist with encyclopedic knowledge of package managers, CLI tools, and framework ecosystems. You are the "Commands Master" — you know every flag, every command, and every quirk of npm, yarn, pnpm, dotnet CLI, NuGet, and any other package management tool relevant to the project.
**Your Core Identity**: You are a pure executor. You do not plan, organize, or architect. You receive a task — install this, remove that, fix this conflict — and you execute the precise commands needed. You are surgical, efficient, and thorough.
**Project Context**:
This project uses:
- **Frontend**: Next.js 16 (React-based, likely using npm/yarn/pnpm)
- **Backend**: C# (likely using dotnet CLI / NuGet)
Always check the project root for lock files (package-lock.json, yarn.lock, pnpm-lock.yaml) and configuration files to determine which package manager is in use before running any commands. Never mix package managers.
**Operational Rules**:
1. **Detect Before Acting**: Before installing or modifying anything, check:
- Which package manager is being used (check lock files)
- Current installed versions of related packages
- The project's Node.js version or .NET version if relevant
- Existing configuration files that might be affected
2. **Install Smart**:
- Always prefer stable, well-maintained packages with active communities
- Check for known vulnerabilities before installing. If the latest version has a CVE or known vulnerability, install a safe earlier version and note why
- Use exact or appropriate version pinning based on the project's existing conventions
- Install packages as devDependencies when they are build/dev tools, not runtime dependencies
- For C# projects, use the appropriate target framework version
3. **Conflict Resolution**:
- When dependency conflicts arise, analyze the dependency tree
- Identify the root cause of the conflict
- Resolve by finding compatible versions, using overrides/resolutions if necessary
- Always explain what conflict existed and how you resolved it
4. **Vulnerability Handling**:
- Run audit commands (npm audit, dotnet list package --vulnerable) when relevant
- If a requested package version has vulnerabilities, automatically choose the closest safe version
- Report what vulnerability was found and what version you chose instead
5. **Removal Protocol**:
- When removing packages, also check for and clean up:
- Orphaned peer dependencies that were only needed by the removed package
- Configuration files specific to the removed package
- References in project configuration files
6. **Command Execution**:
- Run commands one at a time and verify success before proceeding
- If a command fails, read the error output carefully and adapt
- Never use --force or --legacy-peer-deps as a first resort — only after understanding and documenting why it's needed
7. **Output Protocol**:
- After completing operations, provide a brief summary:
- What was installed/removed/updated
- Version numbers
- Any conflicts resolved
- Any vulnerabilities addressed
- Any manual steps the developer needs to take (e.g., adding environment variables, updating config files)
**Update your agent memory** as you discover dependency patterns, package manager configurations, installed packages, framework versions, and recurring dependency issues in this project. This builds up institutional knowledge across conversations. Write concise notes about what you found and where.
Examples of what to record:
- Which package manager is used (npm/yarn/pnpm) and its version
- .NET SDK version and target frameworks
- Notable dependency constraints or resolutions
- Packages that caused conflicts and how they were resolved
- Custom registry configurations
**What You Do NOT Do**:
- You do not write application code
- You do not plan architecture or project structure
- You do not make decisions about which approach to use for features — you only install what is requested or recommend the best package for a stated purpose
- You do not modify source code files (only package/config files as needed for dependency management)
# Persistent Agent Memory
You have a persistent, file-based memory system at `/Users/nicolaleoneciardi/Documents/repos/cima.it/frontend/.claude/agent-memory/commands-master/`. This directory already exists — write to it directly with the Write tool (do not run mkdir or check for its existence).
You should build up this memory system over time so that future conversations can have a complete picture of who the user is, how they'd like to collaborate with you, what behaviors to avoid or repeat, and the context behind the work the user gives you.
If the user explicitly asks you to remember something, save it immediately as whichever type fits best. If they ask you to forget something, find and remove the relevant entry.
## Types of memory
There are several discrete types of memory that you can store in your memory system:
<types>
<type>
<name>user</name>
<description>Contain information about the user's role, goals, responsibilities, and knowledge. Great user memories help you tailor your future behavior to the user's preferences and perspective. Your goal in reading and writing these memories is to build up an understanding of who the user is and how you can be most helpful to them specifically. For example, you should collaborate with a senior software engineer differently than a student who is coding for the very first time. Keep in mind, that the aim here is to be helpful to the user. Avoid writing memories about the user that could be viewed as a negative judgement or that are not relevant to the work you're trying to accomplish together.</description>
<when_to_save>When you learn any details about the user's role, preferences, responsibilities, or knowledge</when_to_save>
<how_to_use>When your work should be informed by the user's profile or perspective. For example, if the user is asking you to explain a part of the code, you should answer that question in a way that is tailored to the specific details that they will find most valuable or that helps them build their mental model in relation to domain knowledge they already have.</how_to_use>
<examples>
user: I'm a data scientist investigating what logging we have in place
assistant: [saves user memory: user is a data scientist, currently focused on observability/logging]
user: I've been writing Go for ten years but this is my first time touching the React side of this repo
assistant: [saves user memory: deep Go expertise, new to React and this project's frontend — frame frontend explanations in terms of backend analogues]
</examples>
</type>
<type>
<name>feedback</name>
<description>Guidance the user has given you about how to approach work — both what to avoid and what to keep doing. These are a very important type of memory to read and write as they allow you to remain coherent and responsive to the way you should approach work in the project. Record from failure AND success: if you only save corrections, you will avoid past mistakes but drift away from approaches the user has already validated, and may grow overly cautious.</description>
<when_to_save>Any time the user corrects your approach ("no not that", "don't", "stop doing X") OR confirms a non-obvious approach worked ("yes exactly", "perfect, keep doing that", accepting an unusual choice without pushback). Corrections are easy to notice; confirmations are quieter — watch for them. In both cases, save what is applicable to future conversations, especially if surprising or not obvious from the code. Include *why* so you can judge edge cases later.</when_to_save>
<how_to_use>Let these memories guide your behavior so that the user does not need to offer the same guidance twice.</how_to_use>
<body_structure>Lead with the rule itself, then a **Why:** line (the reason the user gave — often a past incident or strong preference) and a **How to apply:** line (when/where this guidance kicks in). Knowing *why* lets you judge edge cases instead of blindly following the rule.</body_structure>
<examples>
user: don't mock the database in these tests — we got burned last quarter when mocked tests passed but the prod migration failed
assistant: [saves feedback memory: integration tests must hit a real database, not mocks. Reason: prior incident where mock/prod divergence masked a broken migration]
user: stop summarizing what you just did at the end of every response, I can read the diff
assistant: [saves feedback memory: this user wants terse responses with no trailing summaries]
user: yeah the single bundled PR was the right call here, splitting this one would've just been churn
assistant: [saves feedback memory: for refactors in this area, user prefers one bundled PR over many small ones. Confirmed after I chose this approach — a validated judgment call, not a correction]
</examples>
</type>
<type>
<name>project</name>
<description>Information that you learn about ongoing work, goals, initiatives, bugs, or incidents within the project that is not otherwise derivable from the code or git history. Project memories help you understand the broader context and motivation behind the work the user is doing within this working directory.</description>
<when_to_save>When you learn who is doing what, why, or by when. These states change relatively quickly so try to keep your understanding of this up to date. Always convert relative dates in user messages to absolute dates when saving (e.g., "Thursday" → "2026-03-05"), so the memory remains interpretable after time passes.</when_to_save>
<how_to_use>Use these memories to more fully understand the details and nuance behind the user's request and make better informed suggestions.</how_to_use>
<body_structure>Lead with the fact or decision, then a **Why:** line (the motivation — often a constraint, deadline, or stakeholder ask) and a **How to apply:** line (how this should shape your suggestions). Project memories decay fast, so the why helps future-you judge whether the memory is still load-bearing.</body_structure>
<examples>
user: we're freezing all non-critical merges after Thursday — mobile team is cutting a release branch
assistant: [saves project memory: merge freeze begins 2026-03-05 for mobile release cut. Flag any non-critical PR work scheduled after that date]
user: the reason we're ripping out the old auth middleware is that legal flagged it for storing session tokens in a way that doesn't meet the new compliance requirements
assistant: [saves project memory: auth middleware rewrite is driven by legal/compliance requirements around session token storage, not tech-debt cleanup — scope decisions should favor compliance over ergonomics]
</examples>
</type>
<type>
<name>reference</name>
<description>Stores pointers to where information can be found in external systems. These memories allow you to remember where to look to find up-to-date information outside of the project directory.</description>
<when_to_save>When you learn about resources in external systems and their purpose. For example, that bugs are tracked in a specific project in Linear or that feedback can be found in a specific Slack channel.</when_to_save>
<how_to_use>When the user references an external system or information that may be in an external system.</how_to_use>
<examples>
user: check the Linear project "INGEST" if you want context on these tickets, that's where we track all pipeline bugs
assistant: [saves reference memory: pipeline bugs are tracked in Linear project "INGEST"]
user: the Grafana board at grafana.internal/d/api-latency is what oncall watches — if you're touching request handling, that's the thing that'll page someone
assistant: [saves reference memory: grafana.internal/d/api-latency is the oncall latency dashboard — check it when editing request-path code]
</examples>
</type>
</types>
## What NOT to save in memory
- Code patterns, conventions, architecture, file paths, or project structure — these can be derived by reading the current project state.
- Git history, recent changes, or who-changed-what — `git log` / `git blame` are authoritative.
- Debugging solutions or fix recipes — the fix is in the code; the commit message has the context.
- Anything already documented in CLAUDE.md files.
- Ephemeral task details: in-progress work, temporary state, current conversation context.
These exclusions apply even when the user explicitly asks you to save. If they ask you to save a PR list or activity summary, ask what was *surprising* or *non-obvious* about it — that is the part worth keeping.
## How to save memories
Saving a memory is a two-step process:
**Step 1** — write the memory to its own file (e.g., `user_role.md`, `feedback_testing.md`) using this frontmatter format:
```markdown
---
name: {{memory name}}
description: {{one-line description — used to decide relevance in future conversations, so be specific}}
type: {{user, feedback, project, reference}}
---
{{memory content — for feedback/project types, structure as: rule/fact, then **Why:** and **How to apply:** lines}}
```
**Step 2** — add a pointer to that file in `MEMORY.md`. `MEMORY.md` is an index, not a memory — each entry should be one line, under ~150 characters: `- [Title](file.md) — one-line hook`. It has no frontmatter. Never write memory content directly into `MEMORY.md`.
- `MEMORY.md` is always loaded into your conversation context — lines after 200 will be truncated, so keep the index concise
- Keep the name, description, and type fields in memory files up-to-date with the content
- Organize memory semantically by topic, not chronologically
- Update or remove memories that turn out to be wrong or outdated
- Do not write duplicate memories. First check if there is an existing memory you can update before writing a new one.
## When to access memories
- When memories seem relevant, or the user references prior-conversation work.
- You MUST access memory when the user explicitly asks you to check, recall, or remember.
- If the user says to *ignore* or *not use* memory: Do not apply remembered facts, cite, compare against, or mention memory content.
- Memory records can become stale over time. Use memory as context for what was true at a given point in time. Before answering the user or building assumptions based solely on information in memory records, verify that the memory is still correct and up-to-date by reading the current state of the files or resources. If a recalled memory conflicts with current information, trust what you observe now — and update or remove the stale memory rather than acting on it.
## Before recommending from memory
A memory that names a specific function, file, or flag is a claim that it existed *when the memory was written*. It may have been renamed, removed, or never merged. Before recommending it:
- If the memory names a file path: check the file exists.
- If the memory names a function or flag: grep for it.
- If the user is about to act on your recommendation (not just asking about history), verify first.
"The memory says X exists" is not the same as "X exists now."
A memory that summarizes repo state (activity logs, architecture snapshots) is frozen in time. If the user asks about *recent* or *current* state, prefer `git log` or reading the code over recalling the snapshot.
## Memory and other forms of persistence
Memory is one of several persistence mechanisms available to you as you assist the user in a given conversation. The distinction is often that memory can be recalled in future conversations and should not be used for persisting information that is only useful within the scope of the current conversation.
- When to use or update a plan instead of memory: If you are about to start a non-trivial implementation task and would like to reach alignment with the user on your approach you should use a Plan rather than saving this information to memory. Similarly, if you already have a plan within the conversation and you have changed your approach persist that change by updating the plan rather than saving a memory.
- When to use or update tasks instead of memory: When you need to break your work in current conversation into discrete steps or keep track of your progress use tasks instead of saving to memory. Tasks are great for persisting information about the work that needs to be done in the current conversation, but memory should be reserved for information that will be useful in future conversations.
- Since this memory is project-scope and shared with your team via version control, tailor your memories to this project
## MEMORY.md
Your MEMORY.md is currently empty. When you save new memories, they will appear here.
+19
View File
@@ -8,6 +8,8 @@
"name": "frontend",
"version": "0.1.0",
"dependencies": {
"@gsap/react": "^2.1.2",
"gsap": "^3.14.2",
"next": "16.2.2",
"react": "19.2.4",
"react-dom": "19.2.4"
@@ -454,6 +456,16 @@
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
}
},
"node_modules/@gsap/react": {
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/@gsap/react/-/react-2.1.2.tgz",
"integrity": "sha512-JqliybO1837UcgH2hVOM4VO+38APk3ECNrsuSM4MuXp+rbf+/2IG2K1YJiqfTcXQHH7XlA0m3ykniFYstfq0Iw==",
"license": "SEE LICENSE AT https://gsap.com/standard-license",
"peerDependencies": {
"gsap": "^3.12.5",
"react": ">=17"
}
},
"node_modules/@humanfs/core": {
"version": "0.19.1",
"resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.1.tgz",
@@ -3798,6 +3810,13 @@
"dev": true,
"license": "ISC"
},
"node_modules/gsap": {
"version": "3.14.2",
"resolved": "https://registry.npmjs.org/gsap/-/gsap-3.14.2.tgz",
"integrity": "sha512-P8/mMxVLU7o4+55+1TCnQrPmgjPKnwkzkXOK1asnR9Jg2lna4tEY5qBJjMmAaOBDDZWtlRjBXjLa0w53G/uBLA==",
"license": "Standard 'no charge' license: https://gsap.com/standard-license.",
"peer": true
},
"node_modules/has-bigints": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.1.0.tgz",
+2
View File
@@ -9,6 +9,8 @@
"lint": "eslint"
},
"dependencies": {
"@gsap/react": "^2.1.2",
"gsap": "^3.14.2",
"next": "16.2.2",
"react": "19.2.4",
"react-dom": "19.2.4"
+18
View File
@@ -40,6 +40,15 @@ html {
scroll-behavior: smooth;
}
/* Scroll snap for section-by-section navigation */
.snap-container {
scroll-snap-type: y proximity;
}
.snap-section {
scroll-snap-align: start;
}
body {
font-family: var(--font-sans);
background: var(--color-background);
@@ -111,3 +120,12 @@ img {
background: var(--color-surface-container-high);
}
}
/* Hide scrollbar for horizontal carousels */
.scrollbar-hide {
-ms-overflow-style: none;
scrollbar-width: none;
}
.scrollbar-hide::-webkit-scrollbar {
display: none;
}
+20 -251
View File
@@ -1,256 +1,25 @@
import Image from "next/image";
import Link from "next/link";
import dynamic from "next/dynamic";
import { Suspense } from "react";
import { LazySection } from "@/components/LazySection";
import { Skeleton, SkeletonWave } from "@/components/Skeleton";
const ServicesSection = dynamic(
() => import("@/components/sections/ServicesSection"),
{
loading: () => (
<div className="py-20 lg:py-32 px-6 lg:px-8">
<div className="max-w-7xl mx-auto">
<Skeleton variant="heading" className="mb-8" />
<div className="grid grid-cols-1 md:grid-cols-3 gap-6">
{Array.from({ length: 5 }).map((_, i) => (
<div key={i} className="bg-surface-container p-8 lg:p-12">
<SkeletonWave height="40px" className="mb-8" />
<SkeletonWave height="20px" className="mb-4" />
<SkeletonWave height="60px" />
</div>
))}
</div>
</div>
</div>
),
}
);
const AboutSection = dynamic(
() => import("@/components/sections/AboutSection"),
{
loading: () => (
<div className="py-20 lg:py-32 px-6 lg:px-8 overflow-hidden bg-white">
<div className="max-w-7xl mx-auto grid grid-cols-1 lg:grid-cols-2 gap-12">
<SkeletonWave width="100%" height="600px" />
<div className="space-y-8">
<Skeleton height="60px" />
<Skeleton height="100px" count={3} />
</div>
</div>
</div>
),
}
);
"use client";
import { useGsapScrollTrigger } from "@/components/hooks/useGsapScrollTrigger";
import HeroSection from "@/components/sections/HeroSection";
import ApproccioSection from "@/components/sections/ApproccioSection";
import BeforeAfterSection from "@/components/sections/BeforeAfterSection";
import ServicesSection from "@/components/sections/ServicesSection";
import AboutSection from "@/components/sections/AboutSection";
import FilosofiaSection from "@/components/sections/FilosofiaSection";
import CtaSection from "@/components/sections/CtaSection";
export default function Home() {
useGsapScrollTrigger();
return (
<>
{/* Hero Section - Priority render for LCP */}
<header className="min-h-screen flex flex-col justify-center px-6 lg:px-8 pt-20">
<div className="max-w-7xl mx-auto w-full grid grid-cols-1 lg:grid-cols-12 gap-8 items-end">
<div className="lg:col-span-10">
<h1 className="text-huge font-black uppercase mb-12">
La{" "}
<span className="text-primary">struttura</span> digitale del
vostro business.
</h1>
<div className="flex flex-col sm:flex-row gap-6">
<Link
href="/contatti"
className="bg-primary text-on-primary px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:brightness-110 active:scale-[0.98] text-center"
>
Inizia il Progetto
</Link>
<a
href="#filosofia"
className="border-2 border-on-background text-on-background px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:bg-on-background hover:text-background active:scale-[0.98] text-center"
>
Scopri il Metodo
</a>
</div>
</div>
</div>
</header>
{/* Approccio / Ecosistema Integrato */}
<section
id="approccio"
className="py-20 lg:py-32 px-6 lg:px-8 bg-surface-container-low"
>
<div className="max-w-7xl mx-auto grid grid-cols-1 md:grid-cols-12 gap-12">
<div className="md:col-span-4">
<p className="text-primary font-bold uppercase tracking-widest text-sm mb-4">
L&apos;Approccio
</p>
<h2 className="text-3xl lg:text-4xl font-black uppercase leading-none">
Tutto Collegato
</h2>
</div>
<div className="md:col-span-7 md:col-start-6">
<p className="text-xl lg:text-2xl leading-relaxed text-on-surface">
Non software isolati, ma infrastrutture digitali portanti. Ogni
componente dialoga con gli altri per creare un sistema unico,
costruito attorno al vostro modo di lavorare.
</p>
</div>
</div>
</section>
{/* Problema / Valore - Lazy loaded */}
<LazySection
className="lazy-section"
skeletonHeight="400px"
skeletonCount={1}
>
<section className="py-20 lg:py-32 px-6 lg:px-8 border-y border-outline-variant/10">
<div className="max-w-7xl mx-auto grid grid-cols-1 md:grid-cols-2 gap-px bg-outline-variant/20">
<div className="bg-background p-8 lg:p-16 space-y-8">
<span className="material-symbols-outlined text-error text-5xl">
architecture
</span>
<h3 className="text-2xl lg:text-3xl font-black uppercase">Prima</h3>
<ul className="space-y-4 text-zinc-500">
{[
"Dati sparsi ovunque",
"Processi manuali e lenti",
"Sistemi vulnerabili",
"Zero visibilità strategica",
].map((item) => (
<li key={item} className="flex items-center gap-2">
<span className="w-1.5 h-1.5 bg-error shrink-0" />
{item}
</li>
))}
</ul>
</div>
<div className="bg-background p-8 lg:p-16 space-y-8">
<span className="material-symbols-outlined text-primary text-5xl">
domain
</span>
<h3 className="text-2xl lg:text-3xl font-black uppercase">Dopo</h3>
<ul className="space-y-4 text-zinc-900">
{[
"Un unico flusso di dati",
"Automazione dove serve",
"Sicurezza di livello enterprise",
"Dashboard per decidere in tempo reale",
].map((item) => (
<li key={item} className="flex items-center gap-2">
<span className="w-1.5 h-1.5 bg-primary shrink-0" />
{item}
</li>
))}
</ul>
</div>
</div>
</section>
</LazySection>
{/* Servizi - Lazy loaded with dynamic import */}
<LazySection className="lazy-section" skeletonHeight="300px">
<Suspense>
<ServicesSection />
</Suspense>
</LazySection>
{/* Chi Siamo - Lazy loaded with dynamic import */}
<LazySection className="lazy-section" skeletonHeight="600px">
<Suspense>
<AboutSection />
</Suspense>
</LazySection>
{/* Filosofia - Lazy loaded */}
<LazySection className="lazy-section" skeletonHeight="300px">
<section
id="filosofia"
className="py-20 lg:py-32 px-6 lg:px-8 bg-dark-bg text-white"
>
<div className="max-w-4xl mx-auto text-center space-y-12">
<h2 className="text-sm font-bold uppercase tracking-[0.4em] text-primary">
La nostra idea
</h2>
<blockquote className="text-3xl md:text-4xl lg:text-6xl font-black leading-tight italic">
&ldquo;La forma segue la funzione. La struttura la rende
duratura.&rdquo;
</blockquote>
<p className="text-zinc-400 text-base lg:text-lg max-w-2xl mx-auto leading-relaxed">
Solido come cemento armato, fluido come un open-space. Zero
fronzoli, massima efficienza.
</p>
</div>
</section>
</LazySection>
{/* CTA / Conversione */}
<section
id="progetti"
className="py-28 lg:py-40 px-6 lg:px-8 bg-primary text-white relative overflow-hidden"
>
<div className="max-w-7xl mx-auto relative z-10">
<div className="max-w-3xl">
<h2 className="text-4xl md:text-6xl lg:text-7xl font-black uppercase mb-12 leading-none">
Pronto a scalare?
</h2>
<Link
href="/contatti"
className="inline-block border-2 border-white bg-white text-primary px-12 py-6 font-black uppercase tracking-widest text-lg lg:text-xl hover:bg-transparent hover:text-white hover:border-2 hover:border-white transition-colors"
>
Contattaci
</Link>
</div>
</div>
<div className="absolute top-0 right-0 h-full w-1/3 opacity-10 pointer-events-none">
<svg
className="h-full w-full"
preserveAspectRatio="none"
viewBox="0 0 100 100"
>
<line
stroke="white"
strokeWidth="0.1"
x1="0"
x2="100"
y1="0"
y2="100"
/>
<line
stroke="white"
strokeWidth="0.1"
x1="0"
x2="100"
y1="20"
y2="120"
/>
<line
stroke="white"
strokeWidth="0.1"
x1="0"
x2="100"
y1="40"
y2="140"
/>
<line
stroke="white"
strokeWidth="0.1"
x1="20"
x2="120"
y1="0"
y2="100"
/>
<line
stroke="white"
strokeWidth="0.1"
x1="40"
x2="140"
y1="0"
y2="100"
/>
</svg>
</div>
</section>
</>
<div className="snap-container">
<HeroSection />
<ApproccioSection />
<BeforeAfterSection />
<ServicesSection />
<AboutSection />
<FilosofiaSection />
<CtaSection />
</div>
);
}
+1 -1
View File
@@ -81,7 +81,7 @@ export default function Footer() {
</p>
</div>
{/* Watermark */}
<span className="hidden lg:block absolute bottom-0 right-0 text-[200px] font-black tracking-tighter leading-none select-none pointer-events-none text-on-surface/10 dark:text-on-surface/5 translate-x-4 translate-y-12 transition-colors duration-300">
<span className="hidden lg:block absolute bottom-0 right-0 text-[185px] font-black tracking-tighter leading-none select-none pointer-events-none text-on-surface/10 dark:text-on-surface/5 translate-x-4 translate-y-12 transition-colors duration-300">
CIMA
</span>
</footer>
@@ -0,0 +1,24 @@
interface ScrollProgressDotsProps {
total: number;
current: number;
className?: string;
}
export default function ScrollProgressDots({
total,
current,
className = "",
}: ScrollProgressDotsProps) {
return (
<div className={`flex gap-2 justify-center ${className}`}>
{Array.from({ length: total }).map((_, i) => (
<div
key={i}
className={`w-2 h-2 rounded-full transition-all duration-300 ${
i === current ? "bg-primary scale-125" : "bg-outline-variant"
}`}
/>
))}
</div>
);
}
+29
View File
@@ -0,0 +1,29 @@
"use client";
import React, { forwardRef } from "react";
interface ScrollSectionProps {
id?: string;
className?: string;
children: React.ReactNode;
isLast?: boolean;
}
const ScrollSection = forwardRef<HTMLElement, ScrollSectionProps>(
({ id, className = "", children, isLast = false }, ref) => {
return (
<section
ref={ref}
id={id}
data-pin-section
{...(isLast ? { "data-pin-last": true } : {})}
className={`min-h-screen flex items-center justify-center px-6 lg:px-8 relative overflow-hidden ${className}`}
style={{ willChange: "transform" }}
>
{children}
</section>
);
}
);
ScrollSection.displayName = "ScrollSection";
export default ScrollSection;
@@ -0,0 +1,21 @@
"use client";
import { useEffect } from "react";
import gsap from "gsap";
import { ScrollTrigger } from "gsap/ScrollTrigger";
gsap.registerPlugin(ScrollTrigger);
export function useGsapScrollTrigger() {
useEffect(() => {
// Refresh ScrollTrigger after layout settles
const timeout = setTimeout(() => ScrollTrigger.refresh(), 100);
const onLoad = () => ScrollTrigger.refresh();
window.addEventListener("load", onLoad);
return () => {
clearTimeout(timeout);
window.removeEventListener("load", onLoad);
};
}, []);
}
@@ -1,45 +1,88 @@
"use client";
import Image from "next/image";
import { useRef } from "react";
import { useGSAP } from "@gsap/react";
import gsap from "gsap";
import { ScrollTrigger } from "gsap/ScrollTrigger";
gsap.registerPlugin(ScrollTrigger);
export default function AboutSection() {
const sectionRef = useRef<HTMLElement>(null);
const imageRef = useRef<HTMLDivElement>(null);
const textRef = useRef<HTMLDivElement>(null);
useGSAP(() => {
if (!sectionRef.current || !textRef.current) return;
gsap.fromTo(
textRef.current,
{ y: 40, opacity: 0 },
{
y: 0,
opacity: 1,
duration: 1,
ease: "power3.out",
scrollTrigger: {
trigger: sectionRef.current,
start: "top 70%",
toggleActions: "play none none reverse",
},
}
);
}, { scope: sectionRef });
return (
<section className="py-20 lg:py-32 px-6 lg:px-8 overflow-hidden bg-white">
<div className="max-w-7xl mx-auto grid grid-cols-1 lg:grid-cols-2 gap-12 lg:gap-20 items-center">
<div className="relative">
<Image
alt="Architettura moderna in vetro e acciaio"
className="w-full grayscale hover:grayscale-0 transition-all duration-700"
src="/images/architecture.jpg"
width={800}
height={600}
loading="lazy"
/>
<div className="absolute -bottom-8 -right-8 bg-primary w-36 h-36 lg:w-48 lg:h-48" />
</div>
<div className="space-y-8">
<h2 className="text-4xl lg:text-5xl font-black uppercase">
Chi Siamo
</h2>
<p className="text-lg lg:text-xl leading-relaxed text-secondary">
CiMa Progetti unisce architettura e software engineering. Costruiamo
sistemi digitali solidi e scalabili per aziende che non accettano
compromessi.
</p>
<div className="flex flex-col sm:flex-row gap-8 lg:gap-12 border-t border-zinc-200 pt-8">
<div>
<p className="text-2xl lg:text-3xl font-black">AI Expert</p>
<p className="text-xs uppercase tracking-widest text-primary font-bold">
Nicola Leone Ciardi
</p>
</div>
<div>
<p className="text-2xl lg:text-3xl font-black">Jr Engineer</p>
<p className="text-xs uppercase tracking-widest text-primary font-bold">
Valentina Madaudo
</p>
</div>
<section
ref={sectionRef}
id="chi-siamo"
className="snap-section min-h-screen flex items-center justify-center px-6 lg:px-8 bg-black relative overflow-hidden"
>
{/* Background Image */}
<div
ref={imageRef}
className="absolute inset-0 z-0"
>
<Image
alt="Architettura moderna in vetro e acciaio"
src="/images/architecture.jpg"
fill
className="object-cover"
priority={false}
/>
<div className="absolute inset-0 bg-black/50" />
</div>
{/* Content Overlay */}
<div ref={textRef} className="max-w-3xl mx-auto text-center text-white relative z-10">
<h2 className="text-huge font-black uppercase mb-8">Chi Siamo</h2>
<p className="text-lg lg:text-xl leading-relaxed mb-12">
CiMa Progetti unisce architettura e software engineering. Costruiamo
sistemi digitali solidi e scalabili per aziende che non accettano
compromessi.
</p>
<div className="flex flex-col sm:flex-row gap-8 lg:gap-12 border-t border-white/30 pt-8 justify-center">
<div>
<p className="text-2xl lg:text-3xl font-black">AI Expert</p>
<p className="text-xs uppercase tracking-widest text-primary font-bold">
Nicola Leone Ciardi
</p>
</div>
<div>
<p className="text-2xl lg:text-3xl font-black">Jr Engineer</p>
<p className="text-xs uppercase tracking-widest text-primary font-bold">
Valentina Madaudo
</p>
</div>
</div>
<div className="mt-12">
<a
href="/contatti"
className="inline-block border-2 border-white bg-white text-dark-bg px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:bg-transparent hover:text-white active:scale-[0.98]"
>
Lavora con Noi
</a>
</div>
</div>
</section>
@@ -0,0 +1,63 @@
"use client";
import { useRef } from "react";
import { useGSAP } from "@gsap/react";
import gsap from "gsap";
import { ScrollTrigger } from "gsap/ScrollTrigger";
gsap.registerPlugin(ScrollTrigger);
export default function ApproccioSection() {
const sectionRef = useRef<HTMLElement>(null);
const contentRef = useRef<HTMLDivElement>(null);
useGSAP(() => {
if (!contentRef.current) return;
const children = contentRef.current.children;
gsap.fromTo(
Array.from(children),
{ y: 40, opacity: 0 },
{
y: 0,
opacity: 1,
duration: 0.8,
stagger: 0.15,
ease: "power3.out",
scrollTrigger: {
trigger: sectionRef.current,
start: "top 70%",
toggleActions: "play none none reverse",
},
}
);
}, { scope: sectionRef });
return (
<section
ref={sectionRef}
id="approccio"
className="snap-section min-h-screen flex items-center justify-center px-6 lg:px-8 bg-surface-container-low"
>
<div ref={contentRef} className="max-w-3xl mx-auto text-center">
<p className="text-primary font-bold uppercase tracking-widest text-sm mb-4">
L&apos;Approccio
</p>
<h2 className="text-huge font-black uppercase mb-8">
Tutto Collegato
</h2>
<p className="text-xl lg:text-2xl leading-relaxed text-on-background mb-12">
Non software isolati, ma infrastrutture digitali portanti. Ogni
componente dialoga con gli altri per creare un sistema unico,
costruito attorno al vostro modo di lavorare.
</p>
<a
href="#servizi"
className="inline-block border-2 border-on-background text-on-background px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:bg-on-background hover:text-background active:scale-[0.98]"
>
Scopri i Servizi
</a>
</div>
</section>
);
}
@@ -0,0 +1,140 @@
"use client";
import { useRef } from "react";
import { useGSAP } from "@gsap/react";
import gsap from "gsap";
import { ScrollTrigger } from "gsap/ScrollTrigger";
gsap.registerPlugin(ScrollTrigger);
export default function BeforeAfterSection() {
const sectionRef = useRef<HTMLElement>(null);
const primaRef = useRef<HTMLDivElement>(null);
const dopoRef = useRef<HTMLDivElement>(null);
const ctaRef = useRef<HTMLDivElement>(null);
useGSAP(() => {
if (!sectionRef.current || !primaRef.current || !dopoRef.current) return;
// Prima fades in first
gsap.fromTo(
primaRef.current,
{ y: 30, opacity: 0 },
{
y: 0,
opacity: 1,
duration: 0.8,
ease: "power3.out",
scrollTrigger: {
trigger: sectionRef.current,
start: "top 70%",
toggleActions: "play none none reverse",
},
}
);
// Dopo fades in with slight delay
gsap.fromTo(
dopoRef.current,
{ y: 30, opacity: 0 },
{
y: 0,
opacity: 1,
duration: 0.8,
delay: 0.3,
ease: "power3.out",
scrollTrigger: {
trigger: sectionRef.current,
start: "top 70%",
toggleActions: "play none none reverse",
},
}
);
// CTA fades in after both panels
if (ctaRef.current) {
gsap.fromTo(
ctaRef.current,
{ y: 20, opacity: 0 },
{
y: 0,
opacity: 1,
duration: 0.6,
delay: 0.6,
ease: "power3.out",
scrollTrigger: {
trigger: sectionRef.current,
start: "top 70%",
toggleActions: "play none none reverse",
},
}
);
}
}, { scope: sectionRef });
return (
<section
ref={sectionRef}
className="snap-section min-h-screen flex items-center justify-center px-6 lg:px-8"
>
<div className="max-w-4xl mx-auto w-full">
<div className="grid grid-cols-1 md:grid-cols-2 gap-px bg-outline-variant/20">
{/* Prima */}
<div
ref={primaRef}
className="bg-background p-8 lg:p-16 space-y-8"
>
<span className="material-symbols-outlined text-error text-5xl">
architecture
</span>
<h3 className="text-2xl lg:text-3xl font-black uppercase">Prima</h3>
<ul className="space-y-4 text-zinc-500">
{[
"Dati sparsi ovunque",
"Processi manuali e lenti",
"Sistemi vulnerabili",
"Zero visibilità strategica",
].map((item) => (
<li key={item} className="flex items-center gap-2">
<span className="w-1.5 h-1.5 bg-error shrink-0" />
{item}
</li>
))}
</ul>
</div>
{/* Dopo */}
<div
ref={dopoRef}
className="bg-background p-8 lg:p-16 space-y-8"
>
<span className="material-symbols-outlined text-primary text-5xl">
domain
</span>
<h3 className="text-2xl lg:text-3xl font-black uppercase">Dopo</h3>
<ul className="space-y-4 text-zinc-900">
{[
"Un unico flusso di dati",
"Automazione dove serve",
"Sicurezza di livello enterprise",
"Dashboard per decidere in tempo reale",
].map((item) => (
<li key={item} className="flex items-center gap-2">
<span className="w-1.5 h-1.5 bg-primary shrink-0" />
{item}
</li>
))}
</ul>
</div>
</div>
<div ref={ctaRef} className="text-center mt-12">
<a
href="/contatti"
className="inline-block bg-primary text-on-primary px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:brightness-110 active:scale-[0.98]"
>
Trasforma il tuo Business
</a>
</div>
</div>
</section>
);
}
@@ -0,0 +1,109 @@
"use client";
import Link from "next/link";
import { useRef } from "react";
import { useGSAP } from "@gsap/react";
import gsap from "gsap";
export default function CtaSection() {
const sectionRef = useRef<HTMLElement>(null);
const headingRef = useRef<HTMLHeadingElement>(null);
const buttonRef = useRef<HTMLAnchorElement>(null);
useGSAP(() => {
if (!headingRef.current || !buttonRef.current) return;
const tl = gsap.timeline({
defaults: { ease: "power3.out" },
scrollTrigger: {
trigger: sectionRef.current,
start: "top 70%",
toggleActions: "play none none reverse",
},
});
tl.fromTo(headingRef.current,
{ scale: 0.8, opacity: 0 },
{ scale: 1, opacity: 1, duration: 0.8 }
).fromTo(buttonRef.current,
{ opacity: 0, y: 20 },
{ opacity: 1, y: 0, duration: 0.6 },
"-=0.4"
);
}, { scope: sectionRef });
return (
<section
ref={sectionRef}
id="progetti"
className="snap-section min-h-screen flex items-center justify-center px-6 lg:px-8 bg-primary text-white relative overflow-hidden"
>
<div className="max-w-4xl mx-auto w-full relative z-10 text-center">
<div className="mx-auto">
<h2
ref={headingRef}
className="text-4xl md:text-6xl lg:text-7xl font-black uppercase mb-12 leading-none"
>
Pronto a scalare?
</h2>
<Link
ref={buttonRef}
href="/contatti"
className="inline-block border-2 border-white bg-white text-primary px-12 py-6 font-black uppercase tracking-widest text-lg lg:text-xl hover:bg-transparent hover:text-white hover:border-2 hover:border-white transition-colors"
>
Contattaci
</Link>
</div>
</div>
{/* Decorative SVG Lines */}
<div className="absolute top-0 right-0 h-full w-1/3 opacity-10 pointer-events-none">
<svg
className="h-full w-full"
preserveAspectRatio="none"
viewBox="0 0 100 100"
>
<line
stroke="white"
strokeWidth="0.1"
x1="0"
x2="100"
y1="0"
y2="100"
/>
<line
stroke="white"
strokeWidth="0.1"
x1="0"
x2="100"
y1="20"
y2="120"
/>
<line
stroke="white"
strokeWidth="0.1"
x1="0"
x2="100"
y1="40"
y2="140"
/>
<line
stroke="white"
strokeWidth="0.1"
x1="20"
x2="120"
y1="0"
y2="100"
/>
<line
stroke="white"
strokeWidth="0.1"
x1="40"
x2="140"
y1="0"
y2="100"
/>
</svg>
</div>
</section>
);
}
@@ -0,0 +1,61 @@
"use client";
import { useRef } from "react";
import { useGSAP } from "@gsap/react";
import gsap from "gsap";
import { ScrollTrigger } from "gsap/ScrollTrigger";
gsap.registerPlugin(ScrollTrigger);
export default function FilosofiaSection() {
const sectionRef = useRef<HTMLElement>(null);
const contentRef = useRef<HTMLDivElement>(null);
useGSAP(() => {
if (!contentRef.current) return;
gsap.fromTo(
Array.from(contentRef.current.children),
{ y: 40, opacity: 0 },
{
y: 0,
opacity: 1,
duration: 0.8,
stagger: 0.15,
ease: "power3.out",
scrollTrigger: {
trigger: sectionRef.current,
start: "top 70%",
toggleActions: "play none none reverse",
},
}
);
}, { scope: sectionRef });
return (
<section
ref={sectionRef}
id="filosofia"
className="snap-section min-h-screen flex items-center justify-center px-6 lg:px-8 bg-dark-bg text-white py-32 lg:py-48"
>
<div ref={contentRef} className="max-w-4xl mx-auto text-center space-y-12">
<h2 className="text-sm font-bold uppercase tracking-[0.4em] text-primary">
La nostra idea
</h2>
<blockquote className="text-3xl md:text-4xl lg:text-6xl font-black leading-tight italic">
&ldquo;La forma segue la funzione. La struttura la rende
duratura.&rdquo;
</blockquote>
<p className="text-zinc-400 text-base lg:text-lg max-w-2xl mx-auto leading-relaxed">
Solido come cemento armato, fluido come un open-space. Zero fronzoli,
massima efficienza.
</p>
<a
href="/contatti"
className="inline-block border-2 border-white text-white px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:bg-white hover:text-dark-bg active:scale-[0.98]"
>
Inizia il Progetto
</a>
</div>
</section>
);
}
@@ -0,0 +1,57 @@
"use client";
import Link from "next/link";
import { useRef } from "react";
import { useGSAP } from "@gsap/react";
import gsap from "gsap";
export default function HeroSection() {
const sectionRef = useRef<HTMLElement>(null);
const headlineRef = useRef<HTMLHeadingElement>(null);
const ctaRef = useRef<HTMLDivElement>(null);
useGSAP(() => {
if (!headlineRef.current || !ctaRef.current) return;
const tl = gsap.timeline({ defaults: { ease: "power3.out" } });
tl.fromTo(headlineRef.current,
{ y: 60, opacity: 0 },
{ y: 0, opacity: 1, duration: 1 }
).fromTo(
Array.from(ctaRef.current.children),
{ y: 30, opacity: 0 },
{ y: 0, opacity: 1, duration: 0.6, stagger: 0.15 },
"-=0.4"
);
}, { scope: sectionRef });
return (
<section
ref={sectionRef}
className="snap-section min-h-screen flex items-center justify-center px-6 lg:px-8 pt-20"
>
<div className="max-w-5xl mx-auto text-center">
<h1
ref={headlineRef}
className="text-huge font-black uppercase mb-12"
>
La <span className="text-primary">struttura</span> digitale del
tuo business.
</h1>
<div ref={ctaRef} className="flex flex-col sm:flex-row gap-6 justify-center">
<Link
href="/contatti"
className="bg-primary text-on-primary px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:brightness-110 active:scale-[0.98] text-center"
>
Inizia il Progetto
</Link>
<a
href="#filosofia"
className="border-2 border-on-background text-on-background px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:bg-on-background hover:text-background active:scale-[0.98] text-center"
>
Scopri il Metodo
</a>
</div>
</div>
</section>
);
}
@@ -1,75 +1,176 @@
"use client";
import { useRef, useState, useCallback, useEffect } from "react";
import { useGSAP } from "@gsap/react";
import gsap from "gsap";
import { ScrollTrigger } from "gsap/ScrollTrigger";
import ScrollProgressDots from "@/components/ScrollProgressDots";
gsap.registerPlugin(ScrollTrigger);
const services = [
{
id: "portali",
title: "Portali & Infrastrutture Digitali",
icon: "hub",
description: "Siti, portali e web app costruiti per funzionare e crescere con voi.",
},
{
id: "database",
title: "Database & Sistemi Gestionali",
icon: "schema",
description: "I vostri dati organizzati, accessibili e pronti per le decisioni che contano.",
},
{
id: "ecommerce",
title: "E-commerce & Piattaforme",
icon: "shopping_bag",
description: "Vendita online integrata con la vostra logistica, pronta a scalare.",
},
{
id: "automazioni",
title: "Automazioni & IA",
icon: "memory",
description:
"Meno lavoro ripetitivo, più tempo per quello che conta. IA anche in locale, i vostri dati restano vostri.",
},
{
id: "cybersecurity",
title: "Cybersicurezza",
icon: "verified_user",
description: "Protezione proattiva e monitoraggio continuo dei vostri asset digitali.",
},
];
export default function ServicesSection() {
const sectionRef = useRef<HTMLElement>(null);
const desktopContainerRef = useRef<HTMLDivElement>(null);
const mobileScrollRef = useRef<HTMLDivElement>(null);
const [currentServiceMobile, setCurrentServiceMobile] = useState(0);
const handleMobileScroll = useCallback(() => {
const container = mobileScrollRef.current;
if (!container) return;
const card = container.querySelector("[data-mobile-card]") as HTMLElement;
if (!card) return;
const cardWidth = card.offsetWidth;
const gap = parseFloat(getComputedStyle(container).gap) || 0;
const index = Math.round(container.scrollLeft / (cardWidth + gap));
setCurrentServiceMobile(Math.min(index, services.length - 1));
}, []);
useEffect(() => {
const container = mobileScrollRef.current;
if (!container) return;
container.addEventListener("scroll", handleMobileScroll, { passive: true });
return () => container.removeEventListener("scroll", handleMobileScroll);
}, [handleMobileScroll]);
useGSAP(() => {
if (!sectionRef.current) return;
const mm = gsap.matchMedia();
mm.add("(min-width: 1024px)", () => {
const cards = desktopContainerRef.current?.querySelectorAll("[data-service-card]");
if (cards && cards.length > 0) {
gsap.fromTo(
Array.from(cards),
{ y: 60, opacity: 0 },
{
y: 0,
opacity: 1,
stagger: 0.1,
duration: 0.8,
ease: "power3.out",
scrollTrigger: {
trigger: sectionRef.current,
start: "top 70%",
toggleActions: "play none none reverse",
},
}
);
}
});
}, { scope: sectionRef });
return (
<section id="servizi" className="py-20 lg:py-32 px-6 lg:px-8">
<div className="max-w-7xl mx-auto">
<div className="grid grid-cols-1 lg:grid-cols-12 gap-12 mb-20 items-end">
<div className="lg:col-span-8">
<h2 className="text-4xl lg:text-5xl font-black uppercase mb-6">
Cosa Facciamo
</h2>
<div className="w-24 h-2 bg-primary mb-8" />
<p className="text-xl text-secondary leading-relaxed max-w-2xl">
Soluzioni su misura per il vostro metodo di lavoro. Automazione,
gestione dati e competenze umane in un unico flusso.
</p>
</div>
<section
ref={sectionRef}
id="servizi"
className="snap-section min-h-screen flex items-center justify-center px-6 lg:px-8"
>
<div className="max-w-7xl mx-auto w-full">
<div className="mb-16 text-center lg:text-left">
<h2 className="text-4xl lg:text-5xl font-black uppercase mb-6">
Cosa Facciamo
</h2>
<div className="w-24 h-2 bg-primary mb-8 hidden lg:block" />
<p className="text-xl text-secondary leading-relaxed max-w-2xl">
Soluzioni su misura per il vostro metodo di lavoro. Automazione,
gestione dati e competenze umane in un unico flusso.
</p>
</div>
<div className="grid grid-cols-1 md:grid-cols-3 gap-6">
{/* Desktop Grid */}
<div ref={desktopContainerRef} className="hidden lg:grid grid-cols-1 md:grid-cols-3 gap-6 mb-12">
{/* Portali */}
<div className="bg-surface-container p-8 lg:p-12 border-t-4 border-primary hover:bg-zinc-900 hover:text-white transition-all duration-500 group">
<div
data-service-card
className="bg-surface-container p-8 lg:p-12 border-t-4 border-primary hover:bg-zinc-900 hover:text-white transition-all duration-500 group"
>
<span className="material-symbols-outlined text-4xl mb-8 block text-primary group-hover:text-white">
hub
</span>
<h3 className="text-xl lg:text-2xl font-black uppercase mb-4">
Portali &amp; Infrastrutture Digitali
{services[0].title}
</h3>
<p className="opacity-70 group-hover:opacity-100">
Siti, portali e web app costruiti per funzionare e crescere con
voi.
{services[0].description}
</p>
</div>
{/* Database */}
<div className="bg-surface-container p-8 lg:p-12 border-t-4 border-primary hover:bg-zinc-900 hover:text-white transition-all duration-500 group">
<div
data-service-card
className="bg-surface-container p-8 lg:p-12 border-t-4 border-primary hover:bg-zinc-900 hover:text-white transition-all duration-500 group"
>
<span className="material-symbols-outlined text-4xl mb-8 block text-primary group-hover:text-white">
schema
</span>
<h3 className="text-xl lg:text-2xl font-black uppercase mb-4">
Database &amp; Sistemi Gestionali
{services[1].title}
</h3>
<p className="opacity-70 group-hover:opacity-100">
I vostri dati organizzati, accessibili e pronti per le decisioni
che contano.
{services[1].description}
</p>
</div>
{/* E-commerce */}
<div className="bg-surface-container p-8 lg:p-12 border-t-4 border-primary hover:bg-zinc-900 hover:text-white transition-all duration-500 group">
<div
data-service-card
className="bg-surface-container p-8 lg:p-12 border-t-4 border-primary hover:bg-zinc-900 hover:text-white transition-all duration-500 group"
>
<span className="material-symbols-outlined text-4xl mb-8 block text-primary group-hover:text-white">
shopping_bag
</span>
<h3 className="text-xl lg:text-2xl font-black uppercase mb-4">
E-commerce &amp; Piattaforme
{services[2].title}
</h3>
<p className="opacity-70 group-hover:opacity-100">
Vendita online integrata con la vostra logistica, pronta a
scalare.
{services[2].description}
</p>
</div>
{/* Automazioni & IA */}
<div className="md:col-span-2 bg-surface-container-high text-on-surface p-8 lg:p-12 flex flex-col md:flex-row justify-between items-center gap-8 group transition-colors duration-300">
<div
data-service-card
className="md:col-span-2 bg-surface-container-high text-on-surface p-8 lg:p-12 flex flex-col md:flex-row justify-between items-center gap-8 group transition-colors duration-300"
>
<div className="max-w-xl">
<h3 className="text-2xl lg:text-3xl font-black uppercase mb-4">
Automazioni &amp; IA
{services[3].title}
</h3>
<p className="opacity-60 text-base lg:text-lg">
Meno lavoro ripetitivo, più tempo per quello che conta.
<br />
IA anche in locale, i vostri dati restano vostri.
{services[3].description}
</p>
</div>
<span className="material-symbols-outlined text-7xl text-primary animate-pulse">
@@ -78,21 +179,64 @@ export default function ServicesSection() {
</div>
{/* Cybersicurezza */}
<div className="bg-primary text-white p-8 lg:p-12 flex flex-col justify-between">
<div
data-service-card
className="bg-primary text-white p-8 lg:p-12 flex flex-col justify-between"
>
<div>
<h3 className="text-xl lg:text-2xl font-black uppercase mb-4">
Cybersicurezza
{services[4].title}
</h3>
<p className="opacity-80">
Protezione proattiva e monitoraggio continuo dei vostri asset
digitali.
</p>
<p className="opacity-80">{services[4].description}</p>
</div>
<span className="material-symbols-outlined text-4xl mt-8">
verified_user
</span>
</div>
</div>
{/* Mobile Carousel — horizontal scroll-snap */}
<div className="lg:hidden mb-8">
<div
ref={mobileScrollRef}
className="flex overflow-x-auto snap-x snap-mandatory scrollbar-hide gap-4"
style={{ WebkitOverflowScrolling: "touch" }}
>
{services.map((service) => (
<div
key={service.id}
data-mobile-card
className="snap-start w-[calc(100vw-3rem)] shrink-0 bg-surface-container p-8 border-t-4 border-primary space-y-6"
>
<span className="material-symbols-outlined text-4xl block text-primary">
{service.icon}
</span>
<h3 className="text-xl font-black uppercase mb-4">
{service.title}
</h3>
<p className="text-on-surface">{service.description}</p>
</div>
))}
</div>
{/* Mobile Progress Dots */}
<div className="flex justify-center mt-6">
<ScrollProgressDots
total={services.length}
current={currentServiceMobile}
/>
</div>
</div>
{/* CTA */}
<div className="text-center mt-12">
<a
href="/contatti"
className="inline-block bg-primary text-on-primary px-10 py-5 font-bold uppercase tracking-widest text-lg transition-all hover:brightness-110 active:scale-[0.98]"
>
Parliamo del tuo Progetto
</a>
</div>
</div>
</section>
);