/*
Theme Name: Notaristefano
Theme URI: https://notaristefano.it/
Author: Notaristefano
Description: Tema block custom per Azienda Agricola Notaristefano.
Version: 1.7.0
Requires at least: 6.6
Requires PHP: 8.1
Text Domain: notaristefano
*/

:root {
  --ns-ivory: #F5F1E8;
  --ns-paper: #FCFAF5;
  --ns-olive: #344525;
  --ns-leaf: #657547;
  --ns-earth: #7A5A3B;
  --ns-citrus: #C99A24;
  --ns-ink: #25251F;
}

body { background: var(--ns-paper); }

.ns-kicker {
  letter-spacing: .12em;
  text-transform: uppercase;
  font-size: .78rem;
  font-weight: 600;
}

.ns-hero {
  min-height: 72vh;
  display: grid;
  align-items: end;
  position: relative;
  overflow: hidden;
}

.ns-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(20,24,14,.74), rgba(20,24,14,.2) 60%, rgba(20,24,14,.04));
  pointer-events: none;
}

.ns-hero > .wp-block-group__inner-container,
.ns-hero > .wp-block-cover__inner-container { position: relative; z-index: 1; }

.ns-card {
  border: 1px solid rgba(52,69,37,.18);
  background: #fff;
}

.ns-link a { text-decoration-thickness: 1px; text-underline-offset: .25em; }

/* v0.3 — internal page system */
.ns-page-hero { min-height: 48vh; display:flex; align-items:flex-end; }
.ns-page-hero h1 { max-width: 920px; }
.ns-page-hero p.has-large-font-size { max-width: 760px; }
.ns-photo-placeholder {
  min-height: 420px;
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid rgba(52,69,37,.16);
  background-image: linear-gradient(135deg, rgba(52,69,37,.03), rgba(201,154,36,.08));
}
.ns-photo-portrait { min-height: 560px; }
.ns-placeholder-label {
  max-width: 280px;
  padding: 1rem;
  letter-spacing:.1em;
  text-transform:uppercase;
  font-size:.72rem;
  opacity:.62;
}
.ns-map-placeholder {
  min-height: 520px;
  display:flex;
  align-items:center;
  justify-content:center;
  margin-top:2.5rem;
  margin-bottom:2.5rem;
  border:1px solid rgba(52,69,37,.18);
  background-image: radial-gradient(circle at 20% 30%, rgba(101,117,71,.11), transparent 20%), radial-gradient(circle at 70% 60%, rgba(122,90,59,.09), transparent 24%);
}
.ns-facts { margin-top:2rem; }
.ns-facts .wp-block-column { border-top:1px solid rgba(52,69,37,.25); padding-top:1.25rem; }
.ns-principles { gap:1rem; margin-top:1rem; }
.ns-principles .ns-card { padding:2rem; }
.ns-principles h3 { margin-top:0; }
@media (max-width: 782px) {
  .ns-page-hero { min-height: 54vh; }
  .ns-photo-placeholder, .ns-map-placeholder { min-height: 320px; }
  .ns-photo-portrait { min-height: 420px; }
  .ns-principles { gap:.75rem; }
}

/* v0.4 — Products & Officina */
.ns-photo-placeholder {
  min-height: 420px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(101,117,71,.12), rgba(201,154,36,.10));
  border: 1px solid rgba(52,69,37,.16);
}
.ns-family-card > .wp-block-group { min-height: 100%; }
.ns-product-details dl {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 1px;
  background: rgba(52,69,37,.12);
  margin: 2rem 0;
}
.ns-product-details dl > div {
  background: var(--wp--preset--color--paper);
  padding: 1.25rem;
}
.ns-product-details dt {
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--wp--preset--color--leaf);
  font-weight: 600;
}
.ns-product-details dd { margin: .35rem 0 0; }
.ns-season-badge {
  display: inline-block;
  padding: .45rem .7rem;
  border: 1px solid currentColor;
  font-size: .78rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}
@media (max-width: 780px) {
  .ns-product-details dl { grid-template-columns: 1fr 1fr; }
  .ns-photo-placeholder { min-height: 280px; }
}


/* v0.5 — Scheda prodotto standard Notaristefano */
.ns-standard-product-sheet { margin-top: clamp(3rem, 7vw, 7rem); }
.ns-product-section { padding: clamp(2.5rem, 5vw, 5rem) max(1.25rem, calc((100vw - 1180px)/2)); border-top: 1px solid rgba(52,69,37,.14); }
.ns-product-section--tinted { background: var(--ns-ivory); }
.ns-section-heading { max-width: 760px; margin-bottom: 2rem; }
.ns-section-heading h2, .ns-professional-cta h2 { margin:.45rem 0 0; font-size: clamp(2rem, 4vw, 3.4rem); line-height:1.03; }
.ns-product-facts { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); margin:0; border-top:1px solid rgba(52,69,37,.2); border-left:1px solid rgba(52,69,37,.2); }
.ns-product-facts > div { padding:1.35rem 1.25rem; border-right:1px solid rgba(52,69,37,.2); border-bottom:1px solid rgba(52,69,37,.2); background:rgba(255,255,255,.55); }
.ns-product-facts dt { font-size:.72rem; text-transform:uppercase; letter-spacing:.09em; color:var(--ns-leaf); font-weight:600; }
.ns-product-facts dd { margin:.45rem 0 0; line-height:1.55; }
.ns-product-facts--primary { grid-template-columns:repeat(6,minmax(0,1fr)); }
.ns-use-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:clamp(1.5rem,3vw,3rem); }
.ns-use-grid > div { border-top:1px solid rgba(52,69,37,.25); padding-top:1.25rem; }
.ns-use-grid h3 { margin-top:0; }
.ns-use-grid ul { padding-left:1.15rem; }
.ns-product-lead { max-width:820px; font-size:1.15rem; line-height:1.7; margin-bottom:2rem; }
.ns-tech-details { border-top:1px solid rgba(52,69,37,.25); border-bottom:1px solid rgba(52,69,37,.25); }
.ns-tech-details summary { cursor:pointer; font-size:1.2rem; padding:1.2rem 0; font-weight:600; }
.ns-tech-details[open] summary { margin-bottom:1.4rem; }
.ns-document-links { display:flex; gap:.75rem; flex-wrap:wrap; }
.ns-professional-cta { background:var(--ns-olive); color:#fff; }
.ns-professional-cta p { max-width:760px; font-size:1.08rem; }
.ns-professional-cta .wp-element-button { background:var(--ns-citrus); color:var(--ns-ink); }
@media(max-width:1000px){
  .ns-product-facts--primary { grid-template-columns:repeat(3,minmax(0,1fr)); }
}
@media(max-width:780px){
  .ns-product-facts,.ns-product-facts--primary { grid-template-columns:1fr 1fr; }
  .ns-use-grid { grid-template-columns:1fr; }
  .ns-product-section { padding-left:1.15rem; padding-right:1.15rem; }
}
@media(max-width:480px){
  .ns-product-facts,.ns-product-facts--primary { grid-template-columns:1fr; }
}

/* v1.0 — installation-ready UI */
html { scroll-behavior: smooth; }
body { overflow-x: hidden; }
a { text-underline-offset: .2em; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 3px solid var(--ns-citrus);
  outline-offset: 3px;
}
.ns-site-header { position: relative; z-index: 50; }
.ns-brand-lockup { min-width: max-content; }
.ns-site-header .wp-block-site-title a { text-decoration: none; color: var(--ns-ink); }
.ns-main-nav .wp-block-navigation-item__content { text-decoration: none; }
.ns-nav-contact > a { border: 1px solid var(--ns-olive); padding: .55rem .8rem !important; }
.ns-story-card { height: 100%; border-top: 1px solid rgba(52,69,37,.2); padding-top: 1rem; }
.ns-story-card .wp-block-post-title { margin-top: .6rem; }
.ns-home-closing .is-style-outline .wp-block-button__link { color: #fff; border-color: rgba(255,255,255,.8); }
.ns-footer-news .ns-form input[type="text"],
.ns-footer-news .ns-form input[type="email"] { background: rgba(255,255,255,.96); }
.ns-form { display: grid; gap: 1rem; max-width: 860px; }
.ns-form-row { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:1rem; }
.ns-form-field { display:flex; flex-direction:column; gap:.4rem; }
.ns-form-field label { font-weight:600; }
.ns-form input[type="text"], .ns-form input[type="email"], .ns-form input[type="tel"], .ns-form select, .ns-form textarea {
  box-sizing:border-box; width:100%; border:1px solid rgba(52,69,37,.35); background:#fff; color:var(--ns-ink); padding:.8rem .9rem; border-radius:0; font:inherit;
}
.ns-form textarea { min-height: 150px; resize: vertical; }
.ns-form-consent { display:flex; gap:.65rem; align-items:flex-start; font-size:.92rem; }
.ns-form-consent input { margin-top:.28rem; }
.ns-form-status { padding:1rem; border-left:4px solid var(--ns-leaf); background:var(--ns-ivory); }
.ns-form-status--error { border-left-color:#9d2a2a; }
.ns-hp { position:absolute !important; left:-10000px !important; width:1px !important; height:1px !important; overflow:hidden !important; }
.ns-newsletter-form { grid-template-columns: 1fr auto; align-items:end; }
.ns-newsletter-form .ns-form-consent, .ns-newsletter-form .ns-form-status { grid-column:1 / -1; }
.ns-newsletter-form button, .ns-form button { min-height: 46px; border:0; padding:.8rem 1.1rem; background:var(--ns-citrus); color:var(--ns-ink); font-weight:700; cursor:pointer; }
.ns-site-header .wp-block-navigation__responsive-container.is-menu-open { padding: 1.5rem; background: var(--ns-paper) !important; color: var(--ns-ink) !important; }
.ns-site-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container { gap: .8rem; font-size: 1.3rem; }
/* WooCommerce basic alignment without overriding templates */
.ns-woocommerce .woocommerce { max-width:1280px; margin-inline:auto; padding-inline:max(1.15rem, 5vw); }
.ns-woocommerce .woocommerce ul.products li.product a img { aspect-ratio:1/1; object-fit:cover; background:var(--ns-ivory); }
.ns-woocommerce .woocommerce div.product { padding-top:clamp(2rem,5vw,5rem); }
.ns-woocommerce .woocommerce div.product .product_title { font-family:var(--wp--preset--font-family--display); font-size:clamp(2.2rem,4vw,4rem); }
.ns-woocommerce .woocommerce button.button, .ns-woocommerce .woocommerce a.button { border-radius:0; background:var(--ns-olive); color:#fff; }
@media (max-width: 900px) {
  .ns-site-header { flex-wrap:nowrap !important; }
  .ns-newsletter-form { grid-template-columns:1fr; }
  .ns-newsletter-form .ns-form-consent, .ns-newsletter-form .ns-form-status { grid-column:auto; }
}
@media (max-width: 782px) {
  .ns-form-row { grid-template-columns:1fr; }
  .ns-story-card { margin-bottom:2rem; }
  .ns-site-header .wp-block-site-title { font-size:1.35rem !important; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}


/* v1.1 — first staging refinement */
.ns-site-header .wp-block-site-title {
  line-height: 1;
  white-space: nowrap;
}
.ns-site-header .wp-block-site-title a { font-weight: 400; }
.ns-hero h1 { max-width: 760px; }
.ns-hero .has-large-font-size { max-width: 680px; font-style: normal !important; }
.ns-home-closing h2, .ns-home-closing h3 { color: inherit; }

@media (max-width: 900px) {
  .ns-site-header {
    padding: 12px 18px !important;
    gap: 12px;
  }
  .ns-brand-lockup { min-width: 0; gap: 8px; }
  .ns-brand-lockup .wp-block-site-logo img { max-height: 42px; width: auto !important; }
  .ns-site-header .wp-block-site-title { font-size: 1.15rem !important; }

  /* Guarantee the WordPress navigation collapses on narrow screens. */
  .ns-main-nav .wp-block-navigation__responsive-container:not(.is-menu-open) {
    display: none !important;
  }
  .ns-main-nav .wp-block-navigation__responsive-container-open {
    display: flex !important;
    align-items: center;
    justify-content: center;
  }
  .ns-main-nav .wp-block-navigation__responsive-container.is-menu-open {
    display: flex !important;
  }

  /* WordPress core normally stacks Columns; keep this as a theme-level safety net. */
  main .wp-block-columns,
  footer .wp-block-columns {
    flex-wrap: wrap !important;
    gap: 1.5rem !important;
  }
  main .wp-block-columns > .wp-block-column,
  footer .wp-block-columns > .wp-block-column {
    flex-basis: 100% !important;
    width: 100% !important;
  }

  main > .wp-block-group.alignfull,
  main > .wp-block-group.alignfull.has-background {
    padding-left: 1.25rem !important;
    padding-right: 1.25rem !important;
    padding-top: 3.75rem !important;
    padding-bottom: 3.75rem !important;
  }
  .ns-hero {
    min-height: 68svh !important;
    padding: 4rem 1.25rem 3rem !important;
    align-items: end;
  }
  .ns-hero::after {
    background: linear-gradient(180deg, rgba(20,24,14,.16), rgba(20,24,14,.72) 78%, rgba(20,24,14,.84));
  }
  .ns-hero h1 {
    font-size: clamp(2.5rem, 10vw, 4rem) !important;
    line-height: .98;
  }
  .ns-hero .has-large-font-size { font-size: 1.05rem !important; line-height: 1.55; }
  .ns-hero .wp-block-buttons { gap: .65rem; }
  .ns-hero .wp-block-button__link { padding: .72rem .95rem; }

  .ns-principles .ns-card { padding: 1.35rem !important; }
  .ns-family-card > .wp-block-group { min-height: auto; }
  .ns-photo-placeholder, .ns-map-placeholder { min-height: 260px !important; }
  .ns-photo-portrait { min-height: 320px !important; }
  .ns-home-closing { padding-top: 4rem !important; padding-bottom: 4rem !important; }
  .ns-footer-news { padding: 3.5rem 1.25rem !important; }
  footer > .wp-block-group.alignfull { padding-left: 1.25rem !important; padding-right: 1.25rem !important; }
}

@media (max-width: 520px) {
  .ns-site-header .wp-block-site-title { font-size: 1rem !important; }
  .ns-brand-lockup .wp-block-site-logo img { max-height: 36px; }
  main > .wp-block-group.alignfull,
  main > .wp-block-group.alignfull.has-background { padding-top: 3rem !important; padding-bottom: 3rem !important; }
  .has-x-large-font-size { font-size: clamp(2rem, 9vw, 3rem) !important; }
  .has-large-font-size { font-size: 1.12rem !important; }
  .ns-kicker { font-size: .7rem; }
}


/* v1.2 — definitive Notaristefano visual system: Fraunces + Manrope */
:root {
  --ns-display: "Fraunces", Georgia, "Times New Roman", serif;
  --ns-sans: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  --ns-earth: #6E543E;
}

html { text-rendering: optimizeLegibility; }
body,
button,
input,
select,
textarea,
.wp-block-navigation,
.wp-element-button {
  font-family: var(--ns-sans) !important;
  font-style: normal;
}
body {
  font-size: 1rem;
  line-height: 1.65;
  letter-spacing: -0.006em;
}

h1, h2, h3, h4, h5, h6,
.wp-block-post-title,
.woocommerce .product_title,
.wp-block-site-title {
  font-family: var(--ns-display) !important;
  font-style: normal !important;
  font-optical-sizing: auto;
  letter-spacing: -0.022em;
  text-wrap: balance;
}
h1 { font-weight: 700 !important; line-height: .97 !important; }
h2 { font-weight: 650 !important; line-height: 1 !important; }
h3, h4, h5, h6 { font-weight: 600 !important; line-height: 1.08 !important; }

/* Editorial italics are reserved for genuine narrative quotes only. */
.wp-block-quote p,
.ns-editorial-quote {
  font-family: var(--ns-display) !important;
  font-style: italic !important;
  font-weight: 450;
}
.has-large-font-size:not(.ns-editorial-quote) { font-style: normal !important; }

.ns-kicker,
.wp-block-post-date,
.woocommerce .product_meta,
.ns-product-facts dt,
.ns-product-details dt {
  font-family: var(--ns-sans) !important;
  font-style: normal !important;
  font-weight: 700;
  letter-spacing: .135em;
  text-transform: uppercase;
}

.wp-element-button,
.wp-block-button__link,
.ns-form button,
.ns-newsletter-form button {
  font-family: var(--ns-sans) !important;
  font-size: .88rem;
  font-weight: 700;
  letter-spacing: .01em;
  padding: .82rem 1.15rem;
  transition: transform .18s ease, background-color .18s ease, color .18s ease, border-color .18s ease;
}
@media (hover:hover) {
  .wp-element-button:hover,
  .wp-block-button__link:hover,
  .ns-form button:hover,
  .ns-newsletter-form button:hover { transform: translateY(-1px); }
}

/* Header: quieter, more editorial, with the brand as the visual anchor. */
.ns-site-header {
  min-height: 76px;
  background: rgba(252,250,245,.97) !important;
}
.ns-brand-lockup { gap: .8rem; }
.ns-brand-lockup .wp-block-site-logo img { width: auto !important; max-height: 50px; object-fit: contain; }
.ns-site-header .wp-block-site-title { font-family: var(--ns-display) !important; font-weight: 600 !important; letter-spacing: -.02em; }
.ns-main-nav .wp-block-navigation-item__content { font-family: var(--ns-sans) !important; font-weight: 650; }
.ns-nav-contact > a { padding: .62rem .88rem !important; }

/* Hero hierarchy: Fraunces leads; Manrope explains. */
.ns-hero h1 { font-family: var(--ns-display) !important; font-weight: 700 !important; font-size: clamp(3rem, 6vw, 5.8rem) !important; max-width: 850px; }
.ns-hero .has-large-font-size { font-family: var(--ns-sans) !important; font-size: clamp(1.05rem, 1.5vw, 1.3rem) !important; line-height: 1.62; max-width: 680px; }

/* Cards stay functional: narrative title + clear explanatory copy. */
.ns-card h3,
.ns-family-card h2,
.ns-story-card .wp-block-post-title,
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-family: var(--ns-display) !important;
}
.ns-card p,
.ns-story-card p,
.ns-product-section p,
.woocommerce {
  font-family: var(--ns-sans) !important;
}

/* The closing statement is sober and agricultural rather than rustic. */
.ns-home-closing {
  background: #6E543E !important;
}
.ns-home-closing h2 { max-width: 820px; margin-left: auto; margin-right: auto; }
.ns-home-closing h3 { font-family: var(--ns-display) !important; font-weight: 600 !important; }

/* More breathing room on editorial sections. */
main > .wp-block-group.alignfull:not(.ns-home-closing):not(.ns-footer-news) {
  scroll-margin-top: 80px;
}
.ns-principles .ns-card { min-height: 100%; }

@media (max-width: 900px) {
  .ns-site-header { min-height: 64px; }
  .ns-brand-lockup .wp-block-site-logo img { max-height: 42px; }
  .ns-hero h1 { font-size: clamp(2.65rem, 10vw, 4.25rem) !important; }
  .ns-hero .has-large-font-size { font-size: 1.02rem !important; }
}

@media (max-width: 520px) {
  body { font-size: .97rem; }
  .ns-site-header .wp-block-site-title { font-size: 1.05rem !important; }
  .ns-brand-lockup .wp-block-site-logo img { max-height: 36px; }
  .ns-hero h1 { font-size: clamp(2.45rem, 11vw, 3.45rem) !important; }
  .ns-kicker { letter-spacing: .12em; }
}

/* v1.3 — icon system + 70% documentary agriculture / 30% Mediterranean editorial */
:root {
  --ns-icon-size: 2.7rem;
  --ns-icon-line: var(--ns-leaf);
}

/* Reusable local SVG icon system. Icons are bundled as masks, so they inherit theme colors. */
.ns-icon {
  --ns-icon-color: var(--ns-icon-line);
}
.ns-icon::before {
  content: "";
  display: block;
  width: var(--ns-icon-size);
  height: var(--ns-icon-size);
  margin-bottom: 1rem;
  background-color: var(--ns-icon-color);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
}
.ns-icon-soil::before { -webkit-mask-image:url("assets/icons/soil.svg"); mask-image:url("assets/icons/soil.svg"); }
.ns-icon-biodiversity::before { -webkit-mask-image:url("assets/icons/biodiversity.svg"); mask-image:url("assets/icons/biodiversity.svg"); }
.ns-icon-time::before { -webkit-mask-image:url("assets/icons/time.svg"); mask-image:url("assets/icons/time.svg"); }
.ns-icon-olive::before { -webkit-mask-image:url("assets/icons/olive.svg"); mask-image:url("assets/icons/olive.svg"); }
.ns-icon-citrus::before { -webkit-mask-image:url("assets/icons/citrus.svg"); mask-image:url("assets/icons/citrus.svg"); }
.ns-icon-officina::before { -webkit-mask-image:url("assets/icons/officina.svg"); mask-image:url("assets/icons/officina.svg"); }
.ns-icon-chef::before { -webkit-mask-image:url("assets/icons/chef.svg"); mask-image:url("assets/icons/chef.svg"); }
.ns-icon-mixology::before { -webkit-mask-image:url("assets/icons/mixology.svg"); mask-image:url("assets/icons/mixology.svg"); }
.ns-icon-retail::before { -webkit-mask-image:url("assets/icons/retail.svg"); mask-image:url("assets/icons/retail.svg"); }
.ns-icon-cover::before { -webkit-mask-image:url("assets/icons/cover.svg"); mask-image:url("assets/icons/cover.svg"); }
.ns-icon-organic::before { -webkit-mask-image:url("assets/icons/organic.svg"); mask-image:url("assets/icons/organic.svg"); }
.ns-icon-observation::before { -webkit-mask-image:url("assets/icons/observation.svg"); mask-image:url("assets/icons/observation.svg"); }
.ns-icon-territory::before { -webkit-mask-image:url("assets/icons/territory.svg"); mask-image:url("assets/icons/territory.svg"); }

/* Agricultural cards: tactile, quiet and slightly editorial rather than app-like. */
.ns-icon-card,
.ns-principles > .wp-block-column.ns-card {
  border: 0;
  border-top: 1px solid rgba(52,69,37,.26);
  background: rgba(255,255,255,.52);
  box-shadow: none;
}
.ns-icon-card {
  padding: 1.65rem !important;
}
.ns-icon-card::before,
.ns-principles > .wp-block-column.ns-icon::before {
  --ns-icon-color: var(--ns-leaf);
}

/* Product families get a restrained agricultural pictogram. */
.ns-icon-family::before {
  --ns-icon-color: var(--ns-leaf);
  width: 2.35rem;
  height: 2.35rem;
  margin-bottom: .9rem;
}
.ns-family-card .has-olive-background-color.ns-icon-family::before {
  --ns-icon-color: var(--ns-citrus);
}

/* Professional section: same icon language, reversed for the dark field. */
.ns-icon-panel {
  --ns-icon-color: var(--ns-citrus);
  padding-top: .25rem;
}
.ns-icon-panel::before {
  width: 2.5rem;
  height: 2.5rem;
}

/* Territory/fact icons are intentionally quieter than product or B2B icons. */
.ns-facts .ns-icon::before {
  --ns-icon-color: var(--ns-leaf);
  width: 2.15rem;
  height: 2.15rem;
  margin-bottom: .65rem;
}

/* 70/30 direction: documentary image fields + Mediterranean editorial texture. */
.ns-photo-placeholder,
.ns-map-placeholder {
  position: relative;
  overflow: hidden;
  background-color: #F0EBDD;
  background-image:
    linear-gradient(135deg, rgba(52,69,37,.035), rgba(201,154,36,.055)),
    radial-gradient(circle at 15% 20%, rgba(52,69,37,.045), transparent 28%);
}
.ns-photo-placeholder::after,
.ns-map-placeholder::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .18;
  background-image: repeating-linear-gradient(0deg, rgba(37,37,31,.04) 0 1px, transparent 1px 4px);
  mix-blend-mode: multiply;
}
.ns-placeholder-label { position: relative; z-index: 1; }

/* Fine Mediterranean accent: short ochre rule under key narrative headings. */
.ns-hero h1::after,
.ns-home-closing h2::after {
  content: "";
  display: block;
  width: 3.6rem;
  height: 2px;
  margin-top: 1.1rem;
  background: var(--ns-citrus);
}
.ns-home-closing h2::after { margin-left:auto; margin-right:auto; }

/* A touch more air: the photography and text should feel observed rather than crowded. */
.ns-family-card > .wp-block-group,
.ns-icon-card,
.ns-icon-panel { transition: border-color .18s ease, background-color .18s ease; }
@media (hover:hover) {
  .ns-icon-card:hover { border-top-color: var(--ns-leaf); background-color: rgba(255,255,255,.76); }
}

@media (max-width: 782px) {
  :root { --ns-icon-size: 2.35rem; }
  .ns-icon-card { padding: 1.3rem !important; }
  .ns-icon-panel { padding-top: .5rem; }
}

/* v1.4 — real company photography / 70% agricultural documentary + 30% Mediterranean editorial */
.ns-real-photo {
  position: relative;
  overflow: hidden;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  border: 1px solid rgba(52,69,37,.12);
}
.ns-photo-landscape { min-height: clamp(330px, 42vw, 560px); }
.ns-photo-editorial { box-shadow: 18px 18px 0 rgba(245,241,232,.9); }
.ns-photo-credit {
  margin-top: .65rem !important;
  margin-bottom: 0 !important;
  font-size: .74rem;
  letter-spacing: .045em;
  color: rgba(37,37,31,.62);
}
.ns-terra-hero {
  background-color: var(--ns-olive) !important;
  background-image: url('assets/images/terra-hero.webp');
  background-position: center 58%;
  min-height: min(72vh, 760px);
  isolation: isolate;
}
.ns-terra-hero::before,
.ns-photo-terra-hero-band::before {
  content:"";
  position:absolute;
  inset:0;
  background: linear-gradient(90deg, rgba(22,27,17,.78) 0%, rgba(22,27,17,.52) 42%, rgba(22,27,17,.15) 76%, rgba(22,27,17,.08) 100%);
  z-index:0;
}
.ns-terra-hero > *, .ns-photo-terra-hero-band > * { position:relative; z-index:1; }
.ns-terra-hero .wp-block-heading { max-width: 880px; }
.ns-terra-hero p.has-large-font-size { max-width: 700px; }

.ns-photo-terra-alba { background-image:url('assets/images/terra-agrumeto-alba.webp'); background-position:center 58%; }
.ns-photo-terra-tramonto { background-image:url('assets/images/terra-tramonto.webp'); background-position:center 58%; }
.ns-photo-terra-panorama { background-image:url('assets/images/terra-panorama.webp'); background-position:center 54%; }
.ns-photo-suolo-verde { background-image:url('assets/images/suolo-oliveto-verde.webp'); background-position:center 55%; }
.ns-photo-suolo-verde-2 { background-image:url('assets/images/suolo-oliveto-verde-2.webp'); background-position:center 50%; }
.ns-photo-suolo-estate { background-image:url('assets/images/suolo-estate.webp'); background-position:center 48%; }
.ns-photo-terra-hero-band {
  position:relative;
  isolation:isolate;
  min-height:430px;
  display:grid;
  place-items:center;
  background-image:url('assets/images/terra-hero.webp');
  background-position:center 56%;
}
.ns-photo-terra-hero-band::before {
  background:rgba(28,35,22,.56);
}
.ns-photo-terra-hero-band h2 { max-width:900px; text-shadow:0 1px 8px rgba(0,0,0,.22); }

.ns-season-grid {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:1rem;
  margin-top:2.5rem;
  margin-bottom:1.5rem;
}
.ns-season-frame, .ns-diptych-frame {
  min-height:420px;
  display:flex;
  align-items:flex-end;
}
.ns-season-frame::after, .ns-diptych-frame::after {
  content:"";
  position:absolute;
  inset:45% 0 0;
  background:linear-gradient(transparent, rgba(15,18,12,.68));
  pointer-events:none;
}
.ns-season-label {
  position:relative;
  z-index:2;
  margin:0 !important;
  padding:1.1rem 1.2rem;
  color:#fff;
  font-family:"Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size:.78rem;
  font-weight:650;
  letter-spacing:.07em;
  text-transform:uppercase;
}
.ns-field-diptych {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:1rem;
  margin-top:2.5rem;
}
.ns-diptych-frame { min-height:540px; }

.ns-story-pillars { margin-top:2.5rem; gap:1rem; }
.ns-story-pillars .wp-block-column,
.ns-officina-methods .wp-block-column {
  padding-top:1.3rem;
  border-top:1px solid rgba(52,69,37,.24);
}
.ns-family-placeholder {
  background-image:linear-gradient(135deg,rgba(52,69,37,.04),rgba(201,154,36,.10));
}

@media (max-width: 782px) {
  .ns-terra-hero { min-height:68vh; background-position:center 55%; }
  .ns-terra-hero::before { background:rgba(20,25,15,.58); }
  .ns-photo-editorial { box-shadow:10px 10px 0 rgba(245,241,232,.9); }
  .ns-season-grid, .ns-field-diptych { grid-template-columns:1fr; }
  .ns-season-frame { min-height:330px; }
  .ns-diptych-frame { min-height:400px; }
  .ns-photo-terra-hero-band { min-height:360px; }
}


/* v1.5 — Come coltiviamo: KNF / IMO, technical depth after the simple story */
.ns-method-origin .wp-block-heading,
.ns-method-pillars > .wp-block-heading,
.ns-measure-section .wp-block-heading,
.ns-transition-section .wp-block-heading { text-wrap: balance; }

.ns-method-grid { gap: 1rem; }
.ns-method-grid .ns-card { padding: 2.25rem; }
.ns-method-grid .ns-card p:last-child { margin-bottom: 0; }

.ns-method-tech { position: relative; overflow: hidden; }
.ns-method-tech::after {
  content: "";
  position: absolute;
  width: 38rem;
  height: 38rem;
  right: -18rem;
  top: -19rem;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 50%;
  box-shadow: 0 0 0 7rem rgba(255,255,255,.018), 0 0 0 14rem rgba(255,255,255,.012);
  pointer-events: none;
}
.ns-method-tech > * { position: relative; z-index: 1; }
.ns-tech-details { margin-top: 2.5rem; }
.ns-tech-details .wp-block-details {
  border-top: 1px solid rgba(255,255,255,.22);
  padding: 1.1rem 0 1.25rem;
  margin: 0;
}
.ns-tech-details .wp-block-details:last-child { border-bottom: 1px solid rgba(255,255,255,.22); }
.ns-tech-details summary {
  cursor: pointer;
  font-family: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-weight: 700;
  color: #fff;
  letter-spacing: .01em;
}
.ns-tech-details details p { max-width: 850px; color: rgba(255,255,255,.82); margin-top: .9rem; }

.ns-measure-list { margin-top: 1.4rem; padding-left: 1.25rem; }
.ns-measure-list li { margin-bottom: .65rem; }
.ns-measure-list li::marker { color: var(--ns-citrus); }

.ns-transition-section .ns-field-diptych { margin-top: 0; }
.ns-transition-section .ns-diptych-frame { min-height: 420px; }

.ns-source-story { max-width: 1100px; }
.ns-source-story .wp-block-group.has-paper-background-color { box-shadow: 0 18px 60px rgba(52,69,37,.06); }
.ns-source-story .wp-block-buttons { margin-top: 1.35rem; }

@media (max-width: 782px) {
  .ns-method-grid .ns-card { padding: 1.5rem; }
  .ns-tech-details { margin-top: 1.75rem; }
  .ns-transition-section .ns-field-diptych { margin-top: 2rem; }
  .ns-transition-section .ns-diptych-frame { min-height: 340px; }
}

/* v1.6 — La nostra terra / Chi siamo / Prodotti / Olio */
.ns-number-facts,
.ns-status-explainer,
.ns-proof-grid,
.ns-oil-facts { margin-top: 2.6rem; gap: 1rem; }

.ns-number-facts > .wp-block-column,
.ns-status-explainer > .wp-block-column,
.ns-proof-grid > .wp-block-column,
.ns-oil-facts > .wp-block-column {
  padding: 1.7rem;
  border-top: 1px solid rgba(52,69,37,.22);
}

.ns-number {
  margin: 0 0 .4rem !important;
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(2.35rem, 4vw, 4.3rem);
  line-height: .95;
  color: var(--ns-olive);
}
.ns-number-word { font-size: clamp(1.85rem, 3vw, 3.15rem); }

.ns-timeline {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 1rem;
  margin-top: 3rem;
}
.ns-timeline::before {
  content: "";
  position: absolute;
  left: 2%; right: 2%; top: 1.1rem;
  height: 1px;
  background: rgba(52,69,37,.22);
}
.ns-timeline-item {
  position: relative;
  padding: 2.35rem 1.4rem 1.4rem;
  background: rgba(255,255,255,.72);
  border: 1px solid rgba(52,69,37,.10);
}
.ns-timeline-item::before {
  content: "";
  position: absolute;
  top: .82rem; left: 1.35rem;
  width: .58rem; height: .58rem;
  border-radius: 50%;
  background: var(--ns-citrus);
  box-shadow: 0 0 0 5px var(--ns-paper);
}
.ns-timeline-year {
  margin: 0 0 .55rem !important;
  font-family: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .10em;
  text-transform: uppercase;
  color: var(--ns-leaf);
}

.ns-status-chip {
  display: inline-flex;
  align-items: center;
  width: auto;
  margin: 0 0 1rem !important;
  padding: .45rem .72rem;
  border-radius: 999px;
  font-family: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  border: 1px solid rgba(52,69,37,.18);
}
.ns-status-harvest { background: #F1E7C8; color: #65501A; }
.ns-status-made { background: #E7E9DD; color: var(--ns-olive); }
.ns-status-available { background: #DFE9D8; color: #2D4B2A; }

.ns-audience-card {
  padding: clamp(2rem,4vw,3.5rem);
  background: var(--ns-ivory);
  border: 1px solid rgba(52,69,37,.12);
}
.ns-audience-card-dark {
  background: var(--ns-olive);
  color: #fff;
}
.ns-audience-card-dark p { color: rgba(255,255,255,.84); }

.ns-oil-hero {
  min-height: min(68vh,720px);
  isolation: isolate;
  background-color: var(--ns-olive) !important;
  background-image: url('assets/images/olio-oliveto-estate.webp');
  background-position: center 52%;
}
.ns-oil-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(90deg,rgba(22,27,17,.78) 0%,rgba(22,27,17,.48) 48%,rgba(22,27,17,.13) 80%);
}
.ns-oil-hero > * { position: relative; z-index: 1; }
.ns-oil-hero .wp-block-heading { max-width: 880px; }
.ns-oil-hero p.has-large-font-size { max-width: 720px; }
.ns-photo-oil-grove {
  background-image: url('assets/images/olio-oliveto-estate.webp');
  background-position: center 55%;
}

.ns-season-card {
  padding: clamp(2rem,4vw,3.2rem);
  border: 1px solid rgba(52,69,37,.14);
  box-shadow: 14px 14px 0 rgba(245,241,232,.95);
}

.ns-proof-grid > .wp-block-column::before,
.ns-oil-facts > .wp-block-column::before,
.ns-about-promise .wp-block-column::before {
  --ns-icon-color: var(--ns-leaf);
  width: 2.15rem;
  height: 2.15rem;
  margin-bottom: .75rem;
}

@media (max-width: 1000px) {
  .ns-timeline { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .ns-timeline::before { display:none; }
}

@media (max-width: 782px) {
  .ns-number-facts,
  .ns-status-explainer,
  .ns-proof-grid,
  .ns-oil-facts { gap: .35rem; }
  .ns-number-facts > .wp-block-column,
  .ns-status-explainer > .wp-block-column,
  .ns-proof-grid > .wp-block-column,
  .ns-oil-facts > .wp-block-column { padding: 1.35rem 0; }
  .ns-timeline { grid-template-columns: 1fr; margin-top: 2rem; }
  .ns-timeline-item { padding: 2.2rem 1.2rem 1.3rem; }
  .ns-oil-hero { min-height: 62vh; background-position: 45% 55%; }
  .ns-oil-hero::before { background: rgba(21,26,17,.58); }
  .ns-season-card { box-shadow: 9px 9px 0 rgba(245,241,232,.95); }
}

/* v1.7 — Foto approvate, incluse nel tema. */
.ns-hero { background-image: url('assets/images/01-panorama-apertura.webp'); background-size: cover; background-position: center 54%; }
.ns-site-photo { width:100%; max-width:576px; margin:24px auto; }
.ns-site-photo img { display:block; width:100%; height:auto; border-radius:3px; }
.ns-site-photo figcaption { font-size:.82rem; line-height:1.5; margin-top:10px; color:var(--wp--preset--color--leaf,#566447); }
.ns-family-photo, .ns-small-photo { width:100%; max-width:400px !important; }
.ns-family-photo img { max-width:400px; cursor:default; }
.ns-bottle-photo { max-width:360px; }
.ns-bottle-photo img { max-height:500px; object-fit:contain; }
.ns-card-photo { margin:20px 0; max-width:none; }
.ns-card-photo img { width:100%; height:220px; object-fit:cover; }
.ns-card-bottle img { object-fit:contain; background:#fff; }
.ns-photo-section { padding:48px 20px; }
.ns-photo-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:32px; align-items:start; }
.ns-photo-grid .ns-site-photo { margin:0 auto; }
.ns-photo-grid img { aspect-ratio:3/2; object-fit:cover; }
.ns-photo-grid .ns-site-photo:last-child img[src*="11-cassetta"] { object-fit:contain; background:#f5f1e8; }
@media(max-width:700px) { .ns-photo-grid { grid-template-columns:1fr; gap:24px; } .ns-site-photo { max-width:min(100%,576px); } .ns-family-photo { max-width:400px !important; } }
