:root {
    --bg: #070a10;
    --bg-alt: #0d1220;
    --card-bg: #121826;
    --accent: #00d9e8;
    --accent-dna: #8b5cf6;
    --accent-nail: #ff3d8a;
    --text-color: #eef3f8;
    --text-muted: #8a94a6;
    --border: #1c2333;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

img { max-width: 100%; display: block; }

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* NAVBAR */
.navbar {
    background: rgba(7, 10, 16, 0.85);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 200;
    border-bottom: 1px solid var(--border);
    padding: 14px 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-color);
    text-decoration: none;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 10px;
}
.logo-mark {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    display: block;
}
.logo-text span { color: var(--accent); }

.nav-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 38px;
    height: 38px;
    background: none;
    border: 1px solid var(--border);
    border-radius: 8px;
    cursor: pointer;
}
.nav-toggle span {
    display: block;
    height: 2px;
    width: 18px;
    margin: 0 auto;
    background: var(--text-color);
    transition: transform 0.25s ease, opacity 0.25s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    left: 0;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 10px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}
.nav-links.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-links a {
    display: block;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.95rem;
    padding: 10px 12px;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
}
.nav-links a:hover { background: rgba(0, 217, 232, 0.08); color: var(--accent); }
.nav-links li:last-child { margin-top: 4px; }
.nav-links .btn-sm { text-align: center; }

/* HERO */
.hero {
    padding: 56px 0 40px;
    background:
        radial-gradient(circle at 15% 0%, rgba(0, 217, 232, 0.12) 0%, transparent 45%),
        radial-gradient(circle at 85% 100%, rgba(139, 92, 246, 0.1) 0%, transparent 50%),
        var(--bg);
}

.hero-grid {
    display: flex;
    flex-direction: column;
    gap: 36px;
}

.hero-text { text-align: left; }

.badge {
    display: inline-block;
    background: rgba(0, 217, 232, 0.1);
    color: var(--accent);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    border: 1px solid rgba(0, 217, 232, 0.35);
}

.hero h1 {
    font-size: clamp(2rem, 6vw, 2.9rem);
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -0.01em;
    margin: 18px 0 16px;
}

.hero p {
    color: var(--text-muted);
    max-width: 520px;
    font-size: 1.05rem;
}

.hero-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 26px;
}

.hero-visual {
    position: relative;
    max-width: 360px;
    margin: 0 auto;
}

.hero-visual img {
    width: 100%;
    aspect-ratio: 703 / 410;
    object-fit: cover;
    border-radius: 20px;
    border: 1px solid var(--border);
}

.hero-visual-tag {
    position: absolute;
    bottom: -14px;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    background: var(--card-bg);
    border: 1px solid var(--border);
    color: var(--text-color);
    font-size: 0.78rem;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 20px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

/* BUTTONS */
.btn {
    display: inline-block;
    padding: 13px 26px;
    background-color: var(--accent);
    color: #04141a;
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 217, 232, 0.35);
}

.btn-alt {
    background-color: transparent;
    border: 1px solid var(--border);
    color: var(--text-color);
}
.btn-alt:hover {
    border-color: var(--accent);
    color: var(--accent);
    box-shadow: none;
}

.btn-sm { padding: 9px 18px; font-size: 0.88rem; }

/* MISSION */
.mission {
    position: relative;
    padding: 90px 0;
    overflow: hidden;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.mission-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.4) saturate(1.05);
}

.mission-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(7,10,16,0.75) 0%, rgba(7,10,16,0.92) 100%);
}

.mission-content {
    position: relative;
    z-index: 2;
    max-width: 640px;
}

.mission h2 {
    font-size: clamp(1.7rem, 5vw, 2.3rem);
    font-weight: 800;
    margin-bottom: 18px;
    letter-spacing: -0.01em;
}

.mission p {
    color: #c7cedb;
    font-size: 1.02rem;
}

.mission-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 28px;
    margin-top: 36px;
}

.stat { display: flex; flex-direction: column; }
.stat strong { font-size: 1.6rem; font-weight: 800; color: var(--accent); }
.stat span { font-size: 0.82rem; color: var(--text-muted); margin-top: 2px; }

/* SERVIZI */
.services { padding: 70px 0; }
.section-title { margin-bottom: 40px; max-width: 520px; }
.section-title h2 { font-size: clamp(1.6rem, 4.5vw, 2.1rem); font-weight: 800; letter-spacing: -0.01em; }
.section-title p { color: var(--text-muted); margin-top: 10px; }

.grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.card {
    display: block;
    background: var(--card-bg);
    border-radius: 14px;
    border: 1px solid var(--border);
    overflow: hidden;
    transition: border-color 0.25s, transform 0.25s;
    text-decoration: none;
    color: inherit;
}
.card:hover { border-color: var(--accent); transform: translateY(-3px); }
.card-highlight { border-color: rgba(139, 92, 246, 0.4); }
.card-highlight:hover { border-color: var(--accent-dna); }

.card-img {
    width: 100%;
    aspect-ratio: 4 / 3;
    height: auto;
    object-fit: cover;
    object-position: center;
}

.card-icon {
    font-size: 2.3rem;
    padding: 28px 24px 0;
}

.card-body { padding: 20px 22px 24px; }
.card-body h3 { font-size: 1.08rem; margin-bottom: 8px; }
.card-body p { color: var(--text-muted); font-size: 0.92rem; }

.card-link {
    display: inline-block;
    margin-top: 12px;
    background: none;
    border: none;
    padding: 0;
    color: var(--accent);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
}
.card-link:hover { text-decoration: underline; }
.card-demo-link {
    display: block;
    margin-top: 8px;
    color: var(--accent-nail);
}

/* BREADCRUMB & SERVICE HERO */
.breadcrumb {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 18px;
}
.breadcrumb a { color: var(--text-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span { margin: 0 6px; }

.service-hero { padding: 40px 0 20px; text-align: left; }
.service-hero h1 {
    font-size: clamp(1.8rem, 5vw, 2.4rem);
    font-weight: 800;
    letter-spacing: -0.01em;
}
.service-tagline {
    color: var(--text-muted);
    max-width: 560px;
    margin-top: 12px;
    font-size: 1rem;
}

.service-detail { border-top: none; padding-top: 30px; }

.dna-demo-btn { margin-top: 16px; width: 100%; }

/* COME FUNZIONA */
.how-it-works { padding: 60px 0 70px; border-top: 1px solid var(--border); }
.how-it-works .section-title { margin-bottom: 34px; max-width: none; text-align: center; }
.how-it-works .section-title h2 { font-size: clamp(1.5rem, 4.5vw, 1.9rem); font-weight: 800; }

.steps-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.step {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 24px;
}
.step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(0, 217, 232, 0.1);
    color: var(--accent);
    font-weight: 800;
    font-size: 0.9rem;
    margin-bottom: 14px;
}
.step h4 { font-size: 1.02rem; margin-bottom: 8px; }
.step p { color: var(--text-muted); font-size: 0.92rem; }

@media (min-width: 720px) {
    .steps-grid { grid-template-columns: repeat(3, 1fr); }
}

/* FOCUS SECTIONS */
.tech-focus { padding: 70px 0; border-top: 1px solid var(--border); }

.focus-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    align-items: center;
}

.focus-grid.reverse .focus-box { order: -1; }

.focus-text h2 {
    font-size: clamp(1.5rem, 4.5vw, 1.9rem);
    font-weight: 800;
    letter-spacing: -0.01em;
    margin-bottom: 16px;
}
.focus-text > p { color: var(--text-muted); }

.check-list { list-style: none; margin: 20px 0 24px; }
.check-list li {
    margin-bottom: 12px;
    color: #c7cedb;
    padding-left: 26px;
    position: relative;
    font-size: 0.95rem;
}
.check-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: 700;
}
.beauty-section .check-list li::before { color: var(--accent-nail); }

/* DNA MOCKUP */
.dna-card-mockup {
    background: linear-gradient(135deg, #1a1230 0%, #0c0f18 100%);
    border: 1px solid var(--accent-dna);
    padding: 32px 28px;
    border-radius: 16px;
    text-align: center;
}

.dna-icon { font-size: 2.8rem; margin-bottom: 12px; }
.dna-card-mockup h4 { font-size: 1.05rem; margin-bottom: 8px; }
.dna-card-mockup p { color: var(--text-muted); font-size: 0.9rem; }
.code-box {
    background: rgba(0,0,0,0.45);
    padding: 12px;
    border-radius: 8px;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.85rem;
    margin-top: 16px;
    color: var(--accent);
    word-break: break-word;
}

/* BEAUTY PHOTO */
.beauty-section .focus-box {
    display: flex;
    justify-content: center;
}
.nail-photo {
    max-width: 280px;
    border-radius: 18px;
    border: 1px solid var(--accent-nail);
    box-shadow: 0 12px 32px rgba(255, 61, 138, 0.15);
}

/* CONTATTI */
.contact {
    padding: 70px 0 80px;
    text-align: center;
    border-top: 1px solid var(--border);
}
.contact h2 { font-size: clamp(1.6rem, 4.5vw, 2rem); font-weight: 800; }
.contact p { color: var(--text-muted); max-width: 460px; margin: 14px auto 26px; }

/* MODALE BAR */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(6px);
    z-index: 1000;
    justify-content: center;
    align-items: flex-end;
    padding: 0;
}

.modal-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 20px 20px 0 0;
    width: 100%;
    max-width: 420px;
    padding: 26px 20px 30px;
    position: relative;
    box-shadow: 0 -10px 30px rgba(0,0,0,0.5);
}

.close-btn {
    position: absolute;
    top: 14px; right: 16px;
    background: none; border: none;
    color: var(--text-muted); font-size: 1.6rem; cursor: pointer; line-height: 1;
}

.modal-header { text-align: center; margin-bottom: 22px; }
.modal-header p { color: var(--text-muted); font-size: 0.9rem; margin-top: 4px; }

.bolt-icon {
    width: 46px; height: 46px;
    background: rgba(0, 217, 232, 0.1);
    border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    margin: 0 auto 14px;
    font-size: 1.4rem; color: #ff9d00;
}

.modal-brochure {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #171f30;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px;
    margin-bottom: 16px;
}
.modal-brochure img {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}
.modal-brochure p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.modal-actions { display: flex; flex-direction: column; gap: 10px; }

.action-btn {
    display: flex; align-items: center; gap: 14px;
    background: #171f30;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px 16px;
    color: #fff;
    cursor: pointer;
    transition: 0.2s;
    text-align: left;
}
.action-btn:hover { background: #1e2740; border-color: var(--accent); }

.btn-icon { font-size: 1.3rem; flex-shrink: 0; }
.btn-icon-img {
    width: 34px; height: 34px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}
.btn-text { font-weight: 600; font-size: 0.92rem; flex: 1; }
.arrow { color: var(--text-muted); }

/* FOOTER */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 56px 0 0;
    background: var(--bg-alt);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 36px;
    padding-bottom: 40px;
}

.footer-brand .logo { font-size: 1.4rem; }
.footer-brand p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 14px;
    max-width: 320px;
}

.footer-col h4 {
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 14px;
}

.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
    border-top: 1px solid var(--border);
    padding: 20px 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--text-muted);
    font-size: 0.82rem;
}

.footer-note { font-size: 0.75rem; opacity: 0.75; }

@media (min-width: 720px) {
    .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

/* TABLET+ */
@media (min-width: 720px) {
    .grid { grid-template-columns: repeat(2, 1fr); }
    .focus-grid { grid-template-columns: 1fr 1fr; gap: 50px; }
    .focus-grid.reverse .focus-box { order: 0; }
    .modal-overlay { align-items: center; }
    .modal-card { border-radius: 20px; }
}

/* DESKTOP+ */
@media (min-width: 960px) {
    .navbar { padding: 18px 0; }
    .nav-toggle { display: none; }
    .nav-links {
        position: static;
        flex-direction: row;
        align-items: center;
        gap: 26px;
        background: none;
        border: none;
        padding: 0;
        opacity: 1;
        visibility: visible;
        transform: none;
    }
    .nav-links a { padding: 6px 2px; }

    .hero { padding: 90px 0 80px; }
    .hero-grid { flex-direction: row; align-items: center; gap: 60px; }
    .hero-text { flex: 1.1; }
    .hero-visual { flex: 0.9; max-width: 360px; margin: 0; }

    .grid { grid-template-columns: repeat(3, 1fr); }
}
