/* =========================================================
   TOPBAR
========================================================= */

.demo-topbar {
    background: var(--color-primary);
    color: var(--color-text-inverse);
    font-size: 12px;
}

.demo-topbar__inner {
    max-width: 1800px;
    margin: 0 auto;
    padding: 4px 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
}

.demo-topbar__item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    line-height: 1;
    white-space: nowrap;
    color: inherit;
}

.demo-topbar__link {
    color: inherit;
    text-decoration: none;
}

/* hover desktop + click mobile */
.demo-topbar__link:hover,
.demo-topbar__link:focus,
.demo-topbar__link:active {
    opacity: 0.9;
    text-decoration: none;
    color: var(--color-accent-light);
}

.demo-topbar .material-icons {
    font-size: 15px;
    color: var(--color-text-inverse);
}

/* =========================================================
   HEADER
========================================================= */

.demo-header {
    background: var(--color-header-bg);
    color: var(--color-text);
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.demo-header-inner {
    max-width: 1800px;
    margin: 0 auto;
    padding: 16px 40px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.demo-header-top {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 32px;
    width: 100%;
}

.demo-logo-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
    white-space: nowrap;
    flex: 0 0 auto;
}

.demo-logo-wrap img {
    transform: scale(1.3);
    transform-origin: left center;
    display: block;
}

.demo-header-search {
    min-width: 0;
    width: 100%;
}

.demo-search-wrap {
    position: relative;
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
}

#mainSearchForm {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--color-bg);
    padding: 6px 16px;
    border-radius: 999px;
    box-shadow: 0 3px 12px rgba(0,0,0,0.25);
}

#searchInput {
    flex: 1 1 auto;
    min-width: 0;
    border: none;
    outline: none;
    font-size: 12px;
    background: transparent;
}

#mainSearchForm button[type="submit"] {
    flex: 0 0 auto;
    background: var(--color-primary-light);
    border: none;
    padding: 6px 20px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    color: var(--color-text-inverse);
}

#searchSuggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 6px;
    background: var(--color-bg);
    border-radius: 12px;
    box-shadow: 0 18px 40px rgba(0,0,0,0.35);
    display: none;
    z-index: 9999;
    padding: 16px 18px 12px;
}

/* =========================================================
   HEADER ACTIONS
========================================================= */

.demo-header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    white-space: nowrap;
    margin-left: auto;
    flex-shrink: 0;
}

.demo-header-actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.user-menu {
    display: inline-flex;
    align-items: center;
}

.user-menu__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
}

.demo-user-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    display: block;
}

/* ===============================
   CART HEADER BUTTON
================================= */

.cart-menu__btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    text-decoration: none;
}

/* ICONA */
.cart-menu__btn .demo-cart-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    display: block;
}

/* BADGE */
.cart-menu__btn .cart-badge {
    position: absolute;
    top: -6px;
    right: -6px;

    min-width: 16px;
    height: 16px;
    padding: 0 4px;

    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;

    display: flex;
    align-items: center;
    justify-content: center;

    background: var(--color-danger-soft);
    color: var(--color-text-inverse);
}

/* ======================
  LANGUAGE SWITCHER
====================== */

#langSwitcher {
    position: relative;
}

/* flag attiva */
#currentLang {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    overflow: hidden;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

#currentLang img {
    width: 26px;
    height: 26px;
    object-fit: cover;
    display: block;
}

/* dropdown compatto */
#langMenu {
    position: absolute;
    top: 34px;
    right: 0;

    background: var(--color-bg);
    border-radius: 10px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);

    display: none;
    z-index: 99999;

    padding: 4px;
    min-width: 80px;
}

/* singola lingua */
#langMenu a {
    display: flex;
    align-items: center;
    gap: 6px;

    padding: 6px 8px;
    border-radius: 8px;

    font-size: 12px;
    font-weight: 600;
    line-height: 1;

    text-decoration: none;
    color: var(--color-text-strong);
    white-space: nowrap;
}

#langMenu a:hover {
    background: var(--color-bg-soft);
}

#langMenu a img {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: block;
}

/* =========================================================
   MENU TOP
========================================================= */

.demo-menu-bar {
    display: flex;
    gap: 26px;
    justify-content: center;
    font-size: 14px;
    flex-wrap: wrap;
}

.demo-menu-link {
    text-decoration: none;
    color: var(--color-text);
    font-weight: 500;
}

.demo-menu-link:hover {
    color: var(--color-primary);
}

/* =========================================================
   HOME – HERO FULL WIDTH VIDEO (stile robodevs)
========================================================= */

.hero-rds {
    position: relative;
    width: 100%;
    height: 68vh;
    min-height: 520px;
    overflow: hidden;
    background: var(--color-black);
}

/* video di sfondo */
.hero-rds__video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    pointer-events: none;
}

/* overlay + gradient per leggibilità testo */
.hero-rds__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        radial-gradient(ellipse at 70% 50%, rgba(0,0,0,0.20), rgba(0,0,0,0.65) 70%),
        linear-gradient(to right, rgba(0,0,0,0.35), rgba(0,0,0,0.10));
}

/* contenitore testo */
.hero-rds__inner {
    position: relative;
    z-index: 2;
    max-width: 1800px;
    margin: 0 auto;
    height: 100%;
    padding: 0 40px;
    display: flex;
    align-items: center;
}

/* contenuto allineato a destra */
.hero-rds__content {
    margin-left: auto;
    text-align: right;
    color: var(--color-text-inverse);
    max-width: 820px;
}

/* WELCOME TO */
.hero-rds__kicker {
    font-size: 14px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--color-overlay-light);
    margin-bottom: 12px;
}

/* titolo */
.hero-rds__title {
    margin: 0;
    font-size: 72px;
    line-height: 0.95;
    font-weight: 800;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

/* payoff */
.hero-rds__tagline {
    margin-top: 18px;
    font-size: 14px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--color-overlay-light-soft);
    border-top: 1px solid var(--color-overlay-light-border);
    padding-top: 14px;
}

/* Responsive */
@media (max-width: 900px) {
    .hero-rds {
        height: 52vh;
        min-height: 360px;
    }

    .hero-rds__title {
        font-size: 44px;
        line-height: 1.02;
    }

    .hero-rds__inner {
        padding: 0 20px;
    }
}

/* =========================================================
   MAIN CONTENT
========================================================= */

.demo-main {
    max-width: 1400px;
    margin: 30px auto;
    padding: 0 40px;
}

.grid-products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

/* =========================================================
   HOME – STRIP INFO responsive
========================================================= */

@media (max-width: 900px) {
    .rd-strip-grid {
        flex-wrap: wrap !important;
        gap: 18px !important;
    }

    .rd-strip-item {
        flex: 1 1 calc(50% - 18px) !important;
        min-width: 240px !important;
    }
}

@media (max-width: 560px) {
    .rd-strip-item {
        flex: 1 1 100% !important;
        min-width: 0 !important;
    }
}

/* =========================================================
   LAYOUT BASE (sticky footer)
========================================================= */

.layout-body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.layout-main {
    flex: 1;
}

/* =========================================================
   FOOTER CONTENT TOP
========================================================= */

.rd-footer {
    margin-top: 48px;
}

.rd-footer-top {
    background: var(--color-bg-muted);
    border-top: 1px solid var(--color-border-dark);
    border-bottom: 1px solid var(--color-border-dark);
    padding: 18px 12px;
}

/* wrapper centrale come nel vecchio sito */
.rd-footer-inner {
    max-width: 1200px;
    margin: 0 auto;
}

/* griglia a 5 colonne */
.rd-footer-top-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(180px, 1fr));
    gap: 18px;
    align-items: start;
}

/* colonne */
.rd-foot-col {
    text-align: center;
    font-size: 12px;
}

.rd-foot-col h3 {
    margin: 0 0 10px 0;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-primary);
}

.rd-foot-icon {
    font-size: 28px;
    color: var(--color-primary);
    transition: color 0.2s ease, transform 0.2s ease;
}


/* immagini */
.rd-foot-img img {
    max-width: 110px;
    height: auto;
}

.rd-foot-img-small img {
    max-width: 70px;
    height: auto;
}

/* testi */
.rd-foot-text {
    line-height: 1.5;
}

/* link informativi */
.rd-foot-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.rd-foot-links li {
    margin: 2px 0;
}

.rd-foot-links a {
    color: var(--color-text-soft);
    text-decoration: none;
    font-size: 12px;
}

.rd-foot-links a:hover {
    text-decoration: underline;
}

/* responsive */
@media (max-width: 1100px) {
    .rd-footer-top-grid {
        grid-template-columns: repeat(3, minmax(180px, 1fr));
    }
}

@media (max-width: 720px) {
    .rd-footer-top-grid {
        grid-template-columns: repeat(2, minmax(160px, 1fr));
    }
}

/* =========================================================
   FOOTER MAP  
========================================================= */

.rd-footer-map {
    display: none;
}

.rd-footer-map-link {
    background: var(--color-bg);
    border-top: 1px solid var(--color-border-dark);
    padding: 16px 12px;
    text-align: center;
}

 
/* =========================================================
   FOOTER BOTTOM
========================================================= */

.rd-footer-bottom {
    background: var(--color-bg);
    border-top: 1px solid var(--color-border-dark);
    padding: 14px 12px;
}

.rd-footer-bottom-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 260px;
    gap: 18px;
    align-items: start;
}

.rd-bottom-col h3 {
    margin: 0 0 8px 0;
    font-size: 13px;
    font-weight: 700;
    color: var(--color-primary);
}

.rd-bottom-col p {
    margin: 0;
    font-size: 12px;
    color: var(--color-text-mid);
    line-height: 1.5;
}

.rd-bottom-col a {
    color: var(--color-primary);
    text-decoration: none;
}

.rd-bottom-col a:hover {
    text-decoration: underline;
}

/* Socials: come vecchio (icone grandi a destra) */
.rd-bottom-social {
    text-align: right;
}

.rd-social-icons {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 8px;
}

.rd-social-icons a {
    color: var(--color-text-soft);
    text-decoration: none;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease, transform 0.2s ease;
}

.rd-social-icons a i {
    font-size: 44px;
}

.rd-social-icons a:hover,
.rd-social-icons a:focus {
    color: var(--color-primary-light);
    transform: translateY(-2px);
}

.rd-social-icons a:active {
    color: var(--color-primary);
    transform: scale(0.92);
}

/* Copyright */
.rd-footer-copy {
    background: var(--color-bg-muted);
    border-top: 1px solid var(--color-border-dark);
    padding: 10px 12px;
    font-size: 12px;
    color: var(--color-text-soft);
    text-align: center;
}

/* Responsive */
@media (max-width: 720px) {
    .rd-footer-bottom-grid {
        grid-template-columns: 1fr;
    }

    .rd-bottom-social {
        text-align: left;
    }

    .rd-social-icons {
        justify-content: flex-start;
    }
}

/* =========================================================
   SCROLL TOP BUTTON
========================================================= */

#scrollTopBtn {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 1000;

    display: none;
    width: 48px;
    height: 48px;

    border: none;
    border-radius: 50%;
    background: var(--color-text);
    color: var(--color-text-inverse);

    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,.25);

    align-items: center;
    justify-content: center;
}

#scrollTopBtn i {
    font-size: 20px;
}

#scrollTopBtn:hover {
    background: var(--color-primary);
}

/* ============================
   FOOTER LINKS
============================ */

.rd-foot-links a {
    color: var(--color-text-soft);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.rd-foot-links a:hover,
.rd-foot-links a:focus {
    color: var(--color-primary);
    text-decoration: underline;
}

.rd-foot-links a:active {
    color: var(--color-primary-dark);
}