/**
 * Theme Name: Smartic Child
 * Description: Tema child Castro — rework 2026.
 * Author: Castro
 * Template: smartic
 * Version: 2.0.1
 */

:root {
    --castro-forest: #183b2b;
    --castro-forest-deep: #0d281d;
    --castro-leaf: #4f7045;
    --castro-sage: #aebc91;
    --castro-oil: #c6a34a;
    --castro-oil-light: #e4cd83;
    --castro-cream: #f6f1e5;
    --castro-paper: #fffdf8;
    --castro-earth: #9b6c43;
    --castro-ink: #1c2a23;
    --castro-muted: #667269;
    --castro-line: rgba(24, 59, 43, .13);
    --castro-radius: 24px;
    --castro-shadow: 0 24px 70px rgba(13, 40, 29, .14);
}

html { scroll-behavior: smooth; }

body {
    color: var(--castro-ink);
    background: var(--castro-paper);
    font-family: "DM Sans", Arial, sans-serif;
}

body.home #content { margin: 0; }

.castro-home,
.castro-home * { box-sizing: border-box; }

.castro-home {
    overflow: hidden;
    background: var(--castro-paper);
}

.castro-container {
    width: min(1180px, calc(100% - 48px));
    margin-inline: auto;
}

.castro-kicker {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 18px;
    color: var(--castro-oil);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .18em;
    text-transform: uppercase;
}

.castro-kicker::before {
    width: 30px;
    height: 1px;
    content: "";
    background: currentColor;
}

.castro-display,
.castro-title {
    margin: 0;
    color: var(--castro-forest-deep);
    font-family: "Playfair Display", Georgia, serif;
    font-weight: 600;
    letter-spacing: -.035em;
}

.castro-display {
    max-width: 760px;
    font-size: clamp(52px, 6.4vw, 96px);
    line-height: .98;
}

.castro-title {
    font-size: clamp(38px, 4vw, 58px);
    line-height: 1.06;
}

.castro-lead {
    max-width: 620px;
    margin: 24px 0 0;
    color: var(--castro-muted);
    font-size: clamp(17px, 1.5vw, 20px);
    line-height: 1.75;
}

.castro-btn {
    display: inline-flex;
    min-height: 54px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 0 28px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .02em;
    text-decoration: none !important;
    transition: transform .2s ease, background .2s ease, border-color .2s ease, color .2s ease;
}

.castro-btn:hover { transform: translateY(-2px); }
.castro-btn span { transition: transform .25s ease; }
.castro-btn:hover span { transform: translateX(4px); }
.castro-btn--gold { color: var(--castro-forest-deep) !important; background: var(--castro-oil-light); }
.castro-btn--gold:hover { background: #f1dd9c; }
.castro-btn--ghost { color: #fff !important; border-color: rgba(255,255,255,.36); background: rgba(255,255,255,.06); }
.castro-btn--ghost:hover { border-color: #fff; background: rgba(255,255,255,.12); }
.castro-btn--forest { color: #fff !important; background: var(--castro-forest); }
.castro-btn--forest:hover { background: var(--castro-forest-deep); }

/* Header */
.home .elementor-location-header .elementor-element-d952e99 {
    z-index: 40;
    min-height: 100px !important;
    padding: 8px 3vw;
    border-bottom: 1px solid rgba(255,255,255,.12);
    background: linear-gradient(180deg, rgba(8,31,22,.92), rgba(8,31,22,.64)) !important;
    box-shadow: none;
    backdrop-filter: blur(16px);
}

/* Elementor imposta il logo a 130px nel suo CSS generato: questo selettore
   volutamente più specifico lo porta a una misura davvero percepibile. */
body.home .elementor-601 .elementor-element.elementor-element-b11c02c .elementor-site-logo-wrapper img {
    width: 190px !important;
    height: auto;
    max-width: none;
}
.home .elementor-location-header .main-navigation ul.menu > li > a,
.home .elementor-location-header .site-header-account a,
.home .elementor-location-header .button-search-popup,
.home .elementor-location-header .cart-contents,
.home .elementor-location-header .site-header-button a { color: #fff !important; }
.home .elementor-location-header .main-navigation ul.menu > li > a { font-family: "DM Sans", Arial, sans-serif; font-size: 14px; font-weight: 600; }
.home .elementor-location-header .main-navigation ul.menu > li.current-menu-item > a,
.home .elementor-location-header .main-navigation ul.menu > li > a:hover { color: var(--castro-oil-light) !important; }

/* Hero */
.castro-hero {
    position: relative;
    min-height: 840px;
    display: grid;
    align-items: center;
    background: var(--castro-forest-deep);
    isolation: isolate;
}

.castro-hero::before,
.castro-hero::after {
    position: absolute;
    z-index: -1;
    content: "";
    border-radius: 50%;
    filter: blur(2px);
}

.castro-hero::before {
    width: 620px;
    height: 620px;
    left: -260px;
    bottom: -340px;
    border: 1px solid rgba(228,205,131,.22);
    box-shadow: 0 0 0 80px rgba(228,205,131,.035), 0 0 0 170px rgba(228,205,131,.025);
}

.castro-hero::after {
    width: 500px;
    height: 500px;
    right: 8%;
    top: 16%;
    background: radial-gradient(circle, rgba(198,163,74,.18), transparent 68%);
}

.castro-hero__grid {
    display: grid;
    grid-template-columns: minmax(0, 1.06fr) minmax(380px, .94fr);
    align-items: center;
    gap: 76px;
    padding-top: 150px;
    padding-bottom: 70px;
}

.castro-hero .castro-display { color: #fff; }
.castro-hero .castro-display em { color: var(--castro-oil-light); font-style: italic; }
.castro-hero__text { position: relative; z-index: 2; }
.castro-hero__intro { max-width: 590px; margin: 28px 0 0; color: rgba(255,255,255,.72); font-size: 19px; line-height: 1.75; }
.castro-hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 38px; }
.castro-hero__visual { position: relative; justify-self: end; width: min(100%, 510px); }
.castro-hero__visual::before {
    position: absolute;
    inset: 10% -8% -6% 12%;
    z-index: -1;
    content: "";
    border: 1px solid rgba(228,205,131,.32);
    border-radius: 52% 48% 28% 72% / 46% 30% 70% 54%;
    transform: rotate(8deg);
}
.castro-hero__image {
    display: block;
    width: 100%;
    max-height: 630px;
    object-fit: cover;
    object-position: center;
    border-radius: 240px 240px 32px 32px;
    box-shadow: 0 35px 90px rgba(0,0,0,.3);
    transform: translate3d(var(--castro-mouse-x, 0), var(--castro-mouse-y, 0), 0) scale(1.01);
    transition: transform .45s cubic-bezier(.2,.75,.25,1);
}
.castro-hero__seal {
    position: absolute;
    left: -56px;
    bottom: 64px;
    width: 142px;
    height: 142px;
    display: grid;
    place-items: center;
    padding: 22px;
    border: 1px solid rgba(255,255,255,.3);
    border-radius: 50%;
    color: var(--castro-forest-deep);
    background: var(--castro-oil-light);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
    text-align: center;
    text-transform: uppercase;
    box-shadow: 0 18px 46px rgba(0,0,0,.2);
    animation: castro-seal-float 4.8s ease-in-out infinite;
}

/* Trust strip */
.castro-trust { position: relative; z-index: 3; margin-top: -1px; background: var(--castro-cream); border-bottom: 1px solid var(--castro-line); }
.castro-trust__grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.castro-trust__item { display: flex; align-items: center; gap: 16px; padding: 30px 36px; border-right: 1px solid var(--castro-line); }
.castro-trust__item:last-child { border-right: 0; }
.castro-trust__number { color: var(--castro-oil); font-family: "Playfair Display", Georgia, serif; font-size: 30px; font-weight: 600; }
.castro-trust__item strong { display: block; color: var(--castro-forest); font-size: 15px; }
.castro-trust__item span { display: block; margin-top: 3px; color: var(--castro-muted); font-size: 13px; }

/* Story */
.castro-story { padding: 130px 0; }
.castro-story__grid { display: grid; grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); align-items: center; gap: 88px; }
.castro-story__media { position: relative; min-height: 610px; }
.castro-story__media img { position: absolute; display: block; object-fit: cover; box-shadow: var(--castro-shadow); }
.castro-story__media img:first-child { inset: 0 17% 11% 0; width: 83%; height: 89%; border-radius: 220px 220px 30px 30px; }
.castro-story__media img:last-child { right: 0; bottom: 0; width: 48%; height: 40%; border: 9px solid var(--castro-paper); border-radius: 24px; }
.castro-story__points { display: grid; gap: 20px; margin-top: 34px; }
.castro-story__point { display: grid; grid-template-columns: 42px 1fr; gap: 16px; align-items: start; }
.castro-story__icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; color: var(--castro-forest); background: rgba(174,188,145,.34); font-weight: 700; }
.castro-story__point strong { display: block; color: var(--castro-forest-deep); font-size: 16px; }
.castro-story__point p { margin: 6px 0 0; color: var(--castro-muted); line-height: 1.65; }

/* Products */
.castro-products { padding: 120px 0; background: var(--castro-cream); }
.castro-section-head { display: flex; align-items: end; justify-content: space-between; gap: 40px; margin-bottom: 52px; }
.castro-section-head__copy { max-width: 660px; }
.castro-section-link { color: var(--castro-forest) !important; font-weight: 700; text-decoration: none !important; border-bottom: 1px solid var(--castro-forest); }
.castro-product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.castro-product-card { overflow: hidden; border: 1px solid var(--castro-line); border-radius: var(--castro-radius); background: var(--castro-paper); transition: transform .25s ease, box-shadow .25s ease; }
.castro-product-card:hover { transform: translateY(-7px); box-shadow: var(--castro-shadow); }
.castro-product-card__image { display: grid; min-height: 360px; place-items: center; padding: 30px; background: linear-gradient(145deg, #ede8d8, #faf7ef); }
.castro-product-card__image img { width: 100%; height: 310px; object-fit: contain; mix-blend-mode: multiply; transition: transform .6s cubic-bezier(.2,.75,.25,1); }
.castro-product-card:hover .castro-product-card__image img { transform: scale(1.055) rotate(-1deg); }
.castro-product-card__body { padding: 27px; }
.castro-product-card__eyebrow { margin: 0 0 9px; color: var(--castro-oil); font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.castro-product-card h3 { min-height: 58px; margin: 0; color: var(--castro-forest-deep); font-family: "Playfair Display", Georgia, serif; font-size: 23px; line-height: 1.25; }
.castro-product-card__meta { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--castro-line); }
.castro-product-card__price { color: var(--castro-forest); font-size: 17px; font-weight: 700; }
.castro-product-card__cta { color: var(--castro-earth) !important; font-size: 13px; font-weight: 700; text-decoration: none !important; }

/* Territory */
.castro-territory { position: relative; min-height: 700px; display: grid; align-items: end; padding: 110px 0; background-position: center; background-size: cover; isolation: isolate; }
.castro-territory::before { position: absolute; inset: 0; z-index: -1; content: ""; background: linear-gradient(90deg, rgba(8,31,22,.93) 0%, rgba(8,31,22,.7) 46%, rgba(8,31,22,.15) 100%); }
.castro-territory__card { max-width: 650px; padding: 52px; border: 1px solid rgba(255,255,255,.18); border-radius: var(--castro-radius); background: rgba(13,40,29,.78); backdrop-filter: blur(10px); }
.castro-territory .castro-title { color: #fff; }
.castro-territory p { margin: 24px 0 32px; color: rgba(255,255,255,.74); font-size: 18px; line-height: 1.75; }

/* Recognition + gallery */
.castro-recognition { padding: 125px 0; }
.castro-recognition__grid { display: grid; grid-template-columns: .86fr 1.14fr; align-items: center; gap: 84px; }
.castro-award-card { position: relative; overflow: hidden; min-height: 520px; display: flex; align-items: end; padding: 38px; border-radius: var(--castro-radius); background-position: center; background-size: cover; box-shadow: var(--castro-shadow); }
.castro-award-card::before { position: absolute; inset: 0; content: ""; background: linear-gradient(0deg, rgba(8,31,22,.88), rgba(8,31,22,.08) 70%); }
.castro-award-card__content { position: relative; color: #fff; }
.castro-award-card__content strong { display: block; font-family: "Playfair Display", Georgia, serif; font-size: 34px; }
.castro-award-card__content span { display: block; margin-top: 8px; color: rgba(255,255,255,.72); }
.castro-recognition__stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin: 36px 0 34px; }
.castro-stat { padding: 24px; border: 1px solid var(--castro-line); border-radius: 18px; background: var(--castro-cream); }
.castro-stat strong { display: block; color: var(--castro-oil); font-family: "Playfair Display", Georgia, serif; font-size: 34px; }
.castro-stat span { color: var(--castro-muted); font-size: 13px; }

.castro-gallery { display: grid; grid-template-columns: 1.1fr .9fr .9fr; gap: 12px; padding: 0 12px 12px; background: var(--castro-paper); }
.castro-gallery a { position: relative; overflow: hidden; min-height: 310px; border-radius: 18px; }
.castro-gallery a::after { position: absolute; inset: 0; content: ""; background: linear-gradient(180deg, transparent 55%, rgba(8,31,22,.32)); opacity: 0; transition: opacity .45s ease; }
.castro-gallery img { width: 100%; height: 100%; display: block; object-fit: cover; transition: transform .5s ease; }
.castro-gallery a:hover img { transform: scale(1.04); }
.castro-gallery a:hover::after { opacity: 1; }

/* Motion system — inspired by the original site's layered entrances. */
html.castro-motion-ready .castro-reveal {
    opacity: 0;
    will-change: opacity, transform;
    transition:
        opacity .8s cubic-bezier(.2,.75,.25,1) var(--castro-delay, 0ms),
        transform .8s cubic-bezier(.2,.75,.25,1) var(--castro-delay, 0ms);
}

html.castro-motion-ready .castro-reveal--up { transform: translate3d(0, 44px, 0); }
html.castro-motion-ready .castro-reveal--left { transform: translate3d(-54px, 0, 0); }
html.castro-motion-ready .castro-reveal--right { transform: translate3d(54px, 0, 0); }
html.castro-motion-ready .castro-reveal--scale { transform: scale(.92); }

html.castro-motion-ready .castro-reveal.is-visible {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
}

html.castro-motion-ready .castro-kicker.is-visible::before {
    animation: castro-line-grow .7s cubic-bezier(.2,.75,.25,1) both;
    animation-delay: calc(var(--castro-delay, 0ms) + 220ms);
    transform-origin: left;
}

html.castro-motion-ready .castro-stat.is-visible,
html.castro-motion-ready .castro-trust__item.is-visible {
    animation: castro-soft-pop .55s cubic-bezier(.2,.9,.3,1.25) both;
    animation-delay: calc(var(--castro-delay, 0ms) + 420ms);
}

@keyframes castro-seal-float {
    0%, 100% { transform: translate3d(0, 0, 0) rotate(-2deg); }
    50% { transform: translate3d(0, -10px, 0) rotate(2deg); }
}

@keyframes castro-line-grow {
    from { transform: scaleX(0); }
    to { transform: scaleX(1); }
}

@keyframes castro-soft-pop {
    0% { filter: saturate(.8); }
    55% { filter: saturate(1.15); }
    100% { filter: saturate(1); }
}

/* Final CTA */
.castro-cta { padding: 120px 0; background: var(--castro-forest); }
.castro-cta__inner { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 50px; }
.castro-cta .castro-title { max-width: 760px; color: #fff; }
.castro-cta p { margin: 18px 0 0; color: rgba(255,255,255,.68); font-size: 17px; }

/* Footer */
.elementor-location-footer { background: #091f16; }
.elementor-location-footer .elementor-section { background: transparent !important; }
.elementor-location-footer,
.elementor-location-footer p,
.elementor-location-footer a { color: rgba(255,255,255,.68) !important; }
.elementor-location-footer h1,
.elementor-location-footer h2,
.elementor-location-footer h3,
.elementor-location-footer h4,
.elementor-location-footer strong { color: #fff !important; }

@media (max-width: 1024px) {
    .castro-hero { min-height: auto; }
    .castro-hero__grid { grid-template-columns: 1fr 380px; gap: 40px; padding-top: 150px; }
    .castro-hero__seal { left: -24px; width: 116px; height: 116px; font-size: 11px; }
    .castro-story__grid, .castro-recognition__grid { gap: 50px; }
    .castro-product-card__image { min-height: 300px; }
}

@media (max-width: 767px) {
    .castro-container { width: min(100% - 30px, 620px); }
    .home .elementor-location-header .elementor-element-d952e99 { min-height: 82px !important; padding: 7px 15px; }
    body.home .elementor-601 .elementor-element.elementor-element-b11c02c .elementor-site-logo-wrapper img { width: 160px !important; }
    .castro-hero__grid { grid-template-columns: 1fr; padding-top: 130px; padding-bottom: 60px; }
    .castro-hero__text { text-align: center; }
    .castro-hero .castro-kicker, .castro-hero__actions { justify-content: center; }
    .castro-hero__intro { margin-inline: auto; }
    .castro-hero__visual { justify-self: center; width: min(86vw, 430px); }
    .castro-hero__image { max-height: 520px; border-radius: 190px 190px 26px 26px; }
    .castro-hero__seal { left: -10px; bottom: 28px; }
    .castro-trust__grid { grid-template-columns: 1fr; }
    .castro-trust__item { padding: 22px 0; border-right: 0; border-bottom: 1px solid var(--castro-line); }
    .castro-trust__item:last-child { border-bottom: 0; }
    .castro-story, .castro-products, .castro-recognition, .castro-cta { padding: 82px 0; }
    .castro-story__grid, .castro-recognition__grid { grid-template-columns: 1fr; gap: 48px; }
    .castro-story__media { min-height: 480px; }
    .castro-section-head { display: block; }
    .castro-section-link { display: inline-block; margin-top: 24px; }
    .castro-product-grid { grid-template-columns: 1fr; }
    .castro-product-card h3 { min-height: 0; }
    .castro-territory { min-height: 640px; padding: 70px 0; }
    .castro-territory::before { background: linear-gradient(0deg, rgba(8,31,22,.95), rgba(8,31,22,.28)); }
    .castro-territory__card { padding: 32px 24px; }
    .castro-gallery { grid-template-columns: 1fr; padding-inline: 8px; }
    .castro-gallery a { min-height: 260px; }
    .castro-cta__inner { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .castro-btn, .castro-btn span, .castro-product-card, .castro-product-card__image img, .castro-gallery img, .castro-gallery a::after, .castro-hero__image { transition: none; }
    .castro-hero__seal { animation: none; }
    .castro-reveal { opacity: 1 !important; transform: none !important; animation: none !important; }
}
