/*
Theme Name: FrigoVintage
Theme URI: https://www.frigovintage.it
Author: Criluma Tech
Description: Tema su misura per FrigoVintage: catalogo e negozio di frigoriferi d'epoca e ricambi. Riprende la grafica del restyling ElettroVintage - palette noce, ottone e crema, schede prodotto ordinate, lettura comoda anche da telefono. Compatibile con WooCommerce.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: frigovintage
Tags: e-commerce, custom-colors, custom-menu, custom-logo, featured-images, threaded-comments, translation-ready, two-columns, right-sidebar
*/

/* ==========================================================================
   1. TOKEN  -  tutta la grafica si governa da qui.
   Cambiare un colore in questo blocco lo cambia in tutto il sito.
   ========================================================================== */
:root {
  --fv-paper:      #f4eee3;
  --fv-paper-alt:  #eae0cf;
  --fv-surface:    #fffcf6;
  --fv-surface-2:  #f9f3e8;
  --fv-ink:        #2a231c;
  --fv-ink-soft:   #55483a;
  --fv-muted:      #857664;
  --fv-line:       #ded0b9;
  --fv-line-soft:  #ece2d1;
  --fv-brass:      #a8813a;
  --fv-brass-dark: #86642a;
  --fv-brass-soft: #f0e4c9;
  --fv-brick:      #8f2f22;
  --fv-walnut:     #241c14;
  --fv-walnut-2:   #33281d;
  --fv-cream:      #f6ecd9;
  --fv-ok:         #3f6b46;

  --fv-serif: Georgia, "Iowan Old Style", "Palatino Linotype", Palatino, "Times New Roman", serif;
  --fv-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --fv-radius: 10px;
  --fv-radius-sm: 6px;
  --fv-shadow: 0 1px 2px rgba(42,35,28,.06), 0 6px 18px rgba(42,35,28,.07);
  --fv-shadow-lg: 0 10px 40px rgba(42,35,28,.18);
  --fv-max: 1400px;
}

/* ============================================================ 2. Base */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--fv-paper);
  background-image:
    radial-gradient(circle at 12% -10%, rgba(168,129,58,.10), transparent 45%),
    radial-gradient(circle at 92% 0%, rgba(143,47,34,.07), transparent 40%);
  background-attachment: fixed;
  background-repeat: no-repeat;
  color: var(--fv-ink);
  font-family: var(--fv-sans);
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; }
a { color: var(--fv-brass-dark); text-decoration: none; }
a:hover, a:focus { color: var(--fv-brick); text-decoration: underline; }
:focus-visible { outline: 3px solid var(--fv-brass); outline-offset: 2px; border-radius: 3px; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--fv-serif);
  color: var(--fv-ink);
  line-height: 1.2;
  margin: 0 0 .5em;
}
h1 { font-size: clamp(1.7rem, 1.2rem + 1.8vw, 2.5rem); }
h2 { font-size: clamp(1.4rem, 1.1rem + 1.2vw, 2rem); }
h3 { font-size: 1.25rem; }

hr { border: 0; border-top: 1px solid var(--fv-line); margin: 2rem 0; }

blockquote {
  margin: 1.5rem 0;
  padding: .9rem 1.3rem;
  border-left: 4px solid var(--fv-brass);
  background: var(--fv-surface);
  border-radius: 0 var(--fv-radius-sm) var(--fv-radius-sm) 0;
  font-family: var(--fv-serif);
  font-style: italic;
  color: var(--fv-ink-soft);
}

.fv-skip {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--fv-walnut); color: var(--fv-cream);
  padding: .7rem 1.1rem; border-radius: 0 0 var(--fv-radius-sm) 0;
}
.fv-skip:focus { left: 0; }

.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px; overflow: hidden;
  clip: rect(1px,1px,1px,1px); white-space: nowrap;
}

.fv-wrap { max-width: var(--fv-max); margin: 0 auto; padding-left: 1.25rem; padding-right: 1.25rem; }

/* ========================================================== 3. Testata */
.fv-header {
  position: sticky; top: 0; z-index: 60;
  background: var(--fv-walnut);
  background-image: linear-gradient(180deg, #2c2218 0%, var(--fv-walnut) 100%);
  border-bottom: 3px solid var(--fv-brass);
  box-shadow: 0 2px 14px rgba(0,0,0,.22);
}
.fv-header__inner {
  max-width: var(--fv-max); margin: 0 auto;
  padding: .6rem 1.25rem;
  display: flex; align-items: center; gap: 1rem;
}
.fv-brand { display: flex; align-items: center; gap: .85rem; text-decoration: none !important; min-width: 0; }
.fv-brand img { width: 52px; height: 52px; flex: none; object-fit: cover; border-radius: 50%;
  border: 2px solid var(--fv-brass); background: var(--fv-cream); }
.fv-brand__text { display: flex; flex-direction: column; min-width: 0; }
.fv-brand__name { font-family: var(--fv-serif); font-size: 1.5rem; line-height: 1.05; color: var(--fv-cream); }
.fv-brand__name em { font-style: italic; color: var(--fv-brass); }
.fv-brand__tag {
  font-size: .68rem; letter-spacing: .16em; text-transform: uppercase;
  color: #b9a68a; margin-top: .28rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.fv-nav { margin-left: auto; display: flex; align-items: center; gap: .15rem; flex-wrap: wrap; }
.fv-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: .15rem; flex-wrap: wrap; }
.fv-nav li { position: relative; }
.fv-nav a {
  display: block; padding: .5rem .78rem;
  color: #e6dac5; font-size: .93rem; font-weight: 500;
  border-radius: var(--fv-radius-sm); text-decoration: none !important; white-space: nowrap;
  transition: color .15s ease, background-color .15s ease;
}
.fv-nav a:hover { color: #fff; background: rgba(168,129,58,.22); }
.fv-nav .current-menu-item > a,
.fv-nav .current_page_item > a,
.fv-nav .current-menu-ancestor > a { color: var(--fv-brass); }

/* sottomenu */
.fv-nav ul ul {
  display: none; position: absolute; left: 0; top: 100%;
  min-width: 220px; flex-direction: column; align-items: stretch; gap: 0;
  background: var(--fv-walnut-2); border: 1px solid rgba(246,236,217,.15);
  border-radius: var(--fv-radius-sm); padding: .35rem; z-index: 70;
  box-shadow: 0 14px 30px rgba(0,0,0,.35);
}
.fv-nav li:hover > ul, .fv-nav li:focus-within > ul { display: flex; }
.fv-nav ul ul a { white-space: normal; }

.fv-navtoggle {
  display: none; margin-left: auto;
  padding: .55rem .8rem; font: inherit; font-size: .9rem;
  color: var(--fv-cream); background: transparent;
  border: 1px solid rgba(230,218,197,.4); border-radius: var(--fv-radius-sm); cursor: pointer;
}
.fv-navtoggle:hover { background: rgba(168,129,58,.22); }

.fv-cart {
  display: inline-flex; align-items: center; gap: .4rem;
  margin-left: .4rem; padding: .5rem .85rem;
  background: var(--fv-brass); color: var(--fv-walnut) !important;
  font-weight: 700; font-size: .9rem;
  border-radius: var(--fv-radius-sm); text-decoration: none !important;
}
.fv-cart:hover { background: #c39a4c; color: var(--fv-walnut) !important; }
.fv-cart__count {
  background: var(--fv-walnut); color: var(--fv-cream);
  border-radius: 999px; padding: 0 .45rem; font-size: .78rem; line-height: 1.5;
}

/* ========================================================== 4. Impianto */
.fv-layout {
  max-width: var(--fv-max); margin: 0 auto;
  padding: 1.75rem 1.25rem 3rem;
  display: grid; grid-template-columns: minmax(0,1fr) 280px; gap: 2rem;
  align-items: start;
}
.fv-layout--full { grid-template-columns: minmax(0,1fr); }
.fv-main { min-width: 0; }

.fv-pagehead { border-bottom: 1px solid var(--fv-line); padding-bottom: .9rem; margin-bottom: 1.75rem; }
.fv-pagehead h1 { margin: 0; }
.fv-pagehead p { margin: .35rem 0 0; color: var(--fv-muted); font-size: .95rem; }

.fv-breadcrumb { font-size: .88rem; color: var(--fv-muted); margin-bottom: .9rem; }
.fv-breadcrumb a { color: var(--fv-muted); }
.fv-breadcrumb a:hover { color: var(--fv-brick); }

/* ========================================================== 5. Barra laterale */
.fv-sidebar {
  background: var(--fv-surface); border: 1px solid var(--fv-line);
  border-radius: var(--fv-radius); box-shadow: var(--fv-shadow);
  padding: 1.1rem 1rem; font-size: .94rem;
}
.fv-sidebar .widget + .widget { margin-top: 1.6rem; padding-top: 1.4rem; border-top: 1px solid var(--fv-line-soft); }
.fv-sidebar .widget-title, .fv-sidebar h2, .fv-sidebar h3 {
  font-family: var(--fv-serif); font-size: .8rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--fv-brass-dark);
  margin: 0 0 .75rem; padding-bottom: .5rem; border-bottom: 1px solid var(--fv-line-soft);
}
.fv-sidebar ul { list-style: none; margin: 0; padding: 0; }
.fv-sidebar li { margin: 1px 0; }
.fv-sidebar li a {
  display: block; padding: .42rem .55rem;
  color: var(--fv-ink-soft); border-radius: var(--fv-radius-sm);
  border-left: 3px solid transparent; text-decoration: none !important; line-height: 1.35;
  transition: background-color .14s ease, border-color .14s ease, color .14s ease;
}
.fv-sidebar li a:hover { background: var(--fv-surface-2); border-left-color: var(--fv-brass); color: var(--fv-brick); }
.fv-sidebar li.current-cat > a, .fv-sidebar li.current-menu-item > a {
  background: var(--fv-brass-soft); border-left-color: var(--fv-brass);
  color: var(--fv-ink); font-weight: 600;
}
.fv-sidebar .count { color: var(--fv-muted); font-size: .85em; }

/* ========================================================== 6. Pulsanti */
.fv-btn,
button, input[type="submit"], input[type="button"], input[type="reset"],
.wp-block-button__link {
  display: inline-block; padding: .62rem 1.3rem;
  font: inherit; font-size: .93rem; font-weight: 600;
  color: var(--fv-walnut); background: var(--fv-brass);
  border: 1px solid var(--fv-brass-dark); border-radius: var(--fv-radius-sm);
  cursor: pointer; text-decoration: none !important;
  transition: background-color .15s ease, transform .15s ease;
}
.fv-btn:hover, button:hover, input[type="submit"]:hover, .wp-block-button__link:hover {
  background: #bd934a; color: var(--fv-walnut); transform: translateY(-1px);
}
.fv-btn--ghost {
  background: var(--fv-surface); color: var(--fv-ink); border-color: var(--fv-line);
}
.fv-btn--ghost:hover { background: var(--fv-brass-soft); border-color: var(--fv-brass); color: var(--fv-brick); }
.fv-btn--lg { padding: .85rem 1.9rem; font-size: 1.05rem; border-radius: var(--fv-radius); }

/* ========================================================== 7. Moduli */
input[type="text"], input[type="email"], input[type="tel"], input[type="url"],
input[type="search"], input[type="number"], input[type="password"], input[type="date"],
input:not([type]), select, textarea {
  width: 100%; max-width: 100%; padding: .6rem .75rem;
  font: inherit; font-size: .95rem; color: var(--fv-ink);
  background: var(--fv-surface); border: 1px solid var(--fv-line);
  border-radius: var(--fv-radius-sm);
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--fv-brass);
  box-shadow: 0 0 0 3px rgba(168,129,58,.18);
}
textarea { min-height: 140px; resize: vertical; }
label { display: inline-block; font-size: .92rem; font-weight: 600; color: var(--fv-ink-soft); margin-bottom: .25rem; }

.fv-search { display: flex; gap: .5rem; }
.fv-search input[type="search"] { flex: 1; }
.fv-search button { flex: none; }

/* ========================================================== 8. Articoli */
.fv-entry { background: var(--fv-surface); border: 1px solid var(--fv-line);
  border-radius: var(--fv-radius); box-shadow: var(--fv-shadow);
  padding: 1.6rem 1.75rem; margin-bottom: 1.5rem; }
.fv-entry__title { margin-top: 0; }
.fv-entry__meta { font-size: .86rem; color: var(--fv-muted); margin-bottom: 1rem; }
.fv-prose { max-width: 72ch; }
.fv-prose p { margin: 0 0 1rem; color: var(--fv-ink-soft); }
.fv-prose ul, .fv-prose ol { color: var(--fv-ink-soft); padding-left: 1.3rem; }
.fv-prose img { border-radius: var(--fv-radius-sm); }

.fv-pagination { display: flex; flex-wrap: wrap; gap: .4rem; margin: 2rem 0; }
.fv-pagination .page-numbers {
  display: inline-block; padding: .5rem .85rem;
  background: var(--fv-surface); border: 1px solid var(--fv-line);
  border-radius: var(--fv-radius-sm); color: var(--fv-ink-soft); text-decoration: none !important;
}
.fv-pagination .page-numbers:hover { border-color: var(--fv-brass); color: var(--fv-brick); }
.fv-pagination .page-numbers.current {
  background: var(--fv-brass); border-color: var(--fv-brass-dark);
  color: var(--fv-walnut); font-weight: 700;
}

/* ========================================================== 9. Home */
.fv-hero {
  max-width: var(--fv-max); margin: 1.75rem auto 0; padding: 0 1.25rem;
  display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1.05fr);
  gap: 2.5rem; align-items: center;
}
.fv-hero--solo { grid-template-columns: minmax(0,1fr); max-width: 980px; }
.fv-hero--solo .fv-hero__lead { max-width: none; }
.fv-hero__eyebrow {
  font-size: .72rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--fv-brass-dark); margin: 0 0 .9rem; font-weight: 700;
}
.fv-hero__title { font-size: clamp(2rem, 1.2rem + 3vw, 3.2rem); line-height: 1.08; margin: 0 0 1rem; }
.fv-hero__title em { font-style: italic; color: var(--fv-brass-dark); }
.fv-hero__lead { font-size: 1.1rem; color: var(--fv-ink-soft); margin: 0 0 1.1rem; max-width: 46ch; }
.fv-hero__actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.4rem; }
.fv-hero__media img { width: 100%; border-radius: var(--fv-radius); border: 1px solid var(--fv-line);
  box-shadow: var(--fv-shadow-lg); }

.fv-section { max-width: var(--fv-max); margin: 0 auto; padding: 3rem 1.25rem; }
.fv-section__title { text-align: center; margin: 0 0 .5rem; }
.fv-section__sub { text-align: center; color: var(--fv-muted); margin: 0 auto 2.25rem; max-width: 62ch; }

.fv-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px,1fr)); gap: .9rem;
  list-style: none; margin: 0; padding: 0; }
.fv-cats a {
  display: flex; align-items: center; gap: .6rem; height: 100%;
  padding: .85rem 1rem; color: var(--fv-ink) !important;
  background: var(--fv-surface); border: 1px solid var(--fv-line);
  border-radius: var(--fv-radius); box-shadow: var(--fv-shadow);
  font-size: .95rem; font-weight: 500; text-decoration: none !important;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}
.fv-cats a::before { content:""; flex:none; width:8px; height:8px; border-radius:50%;
  background: var(--fv-brass); transition: transform .16s ease; }
.fv-cats a:hover { transform: translateY(-2px); border-color: var(--fv-brass); color: var(--fv-brick) !important; }
.fv-cats a:hover::before { transform: scale(1.5); }

.fv-features { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px,1fr)); gap: 1.25rem; }
.fv-feature { background: var(--fv-surface); border: 1px solid var(--fv-line);
  border-radius: var(--fv-radius); box-shadow: var(--fv-shadow); padding: 1.5rem; }
.fv-feature h3 { font-size: 1.15rem; margin: 0 0 .5rem; }
.fv-feature p { margin: 0; color: var(--fv-ink-soft); font-size: .95rem; }
.fv-feature__icon {
  display: flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; margin-bottom: .9rem; border-radius: 50%;
  background: var(--fv-brass-soft); color: var(--fv-brass-dark); font-size: 1.2rem;
}

.fv-band {
  background: var(--fv-walnut);
  background-image: linear-gradient(135deg, #2e2418 0%, var(--fv-walnut) 60%);
  color: var(--fv-cream);
  border-top: 3px solid var(--fv-brass); border-bottom: 3px solid var(--fv-brass);
}
.fv-band h2, .fv-band .fv-section__title { color: var(--fv-cream); }
.fv-band p, .fv-band .fv-section__sub { color: #c5b393; }

/* ========================================================== 10. Footer */
.fv-footer {
  margin-top: 3rem; background: var(--fv-walnut); color: #bfae92;
  border-top: 3px solid var(--fv-brass); font-size: .92rem;
}
.fv-footer__inner {
  max-width: var(--fv-max); margin: 0 auto; padding: 2.5rem 1.25rem 1.5rem;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(210px,1fr)); gap: 2rem;
}
.fv-footer h4, .fv-footer .widget-title {
  font-family: var(--fv-serif); font-size: .8rem; letter-spacing: .16em;
  text-transform: uppercase; color: var(--fv-brass); margin: 0 0 .9rem;
}
.fv-footer a { color: #ddcfb5; }
.fv-footer a:hover { color: var(--fv-brass); }
.fv-footer ul { list-style: none; margin: 0; padding: 0; }
.fv-footer li { margin-bottom: .4rem; }
.fv-footer p { margin: 0 0 .4rem; }
.fv-footer__bottom {
  max-width: var(--fv-max); margin: 0 auto;
  padding: 1rem 1.25rem 2rem; border-top: 1px solid rgba(246,236,217,.12);
  display: flex; flex-wrap: wrap; gap: .75rem; justify-content: space-between;
  font-size: .82rem; color: #93826a;
}

/* ========================================================== 11. Torna su */
.fv-top {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 50;
  width: 44px; height: 44px; padding: 0;
  display: none; align-items: center; justify-content: center;
  color: var(--fv-cream); background: var(--fv-walnut);
  border: 1px solid var(--fv-brass); border-radius: 50%;
  box-shadow: var(--fv-shadow); cursor: pointer; font-size: 1.1rem;
}
.fv-top.is-visible { display: flex; }
.fv-top:hover { background: var(--fv-brass); color: var(--fv-walnut); }

/* ========================================================== 12. Responsive */
@media (max-width: 1100px) {
  .fv-layout { grid-template-columns: minmax(0,1fr); }
  .fv-sidebar { order: 2; }
  .fv-main { order: 1; }
}

@media (max-width: 900px) {
  .fv-navtoggle { display: block; }
  .fv-header__inner { position: relative; flex-wrap: wrap; }
  .fv-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: .5rem .75rem 1rem; background: var(--fv-walnut);
    border-bottom: 3px solid var(--fv-brass);
    box-shadow: 0 14px 26px rgba(0,0,0,.3);
    max-height: 75vh; overflow-y: auto;
  }
  .fv-nav.is-open { display: flex; }
  .fv-nav ul { flex-direction: column; align-items: stretch; gap: 0; width: 100%; }
  .fv-nav a { padding: .75rem .8rem; }
  .fv-nav ul ul { display: flex; position: static; box-shadow: none; border: 0;
    background: transparent; padding: 0 0 0 .9rem; }
  .fv-brand__name { font-size: 1.25rem; }
  .fv-brand img { width: 44px; height: 44px; }
  .fv-hero { grid-template-columns: minmax(0,1fr); gap: 1.75rem; }
  .fv-section { padding: 2.25rem 1.25rem; }
  .fv-entry { padding: 1.2rem 1.1rem; }
}

@media (max-width: 480px) {
  body { font-size: 15px; }
  .fv-brand__tag { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}

/* ========================================================== 13. Stampa */
@media print {
  .fv-header, .fv-footer, .fv-sidebar, .fv-top, .fv-nav { display: none !important; }
  body { background: #fff; color: #000; }
  .fv-layout { display: block; padding: 0; }
}
