/* Stile del sito della galleria */
:root {
  --bg: #f6f2ec; --white: #fff; --ink: #1e1b18; --muted: #7a726a; --line: #e3dcd2;
  --accent: #b5532f; --accent-dark: #93401f; --accent-soft: #f8e8e0; --wall: #ece7df;
  --green: #2e6e46; --green-bg: #e1f0e5; --amber: #966414; --amber-bg: #faeed2; --red: #a03228; --red-bg: #f6e0dc;
  --serif: Georgia, "Times New Roman", serif;
  --sans: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.6 var(--sans); }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
p a, .small a, .crumbs a, dd a { color: var(--accent); }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.2; margin: 0 0 .4em; }
h1 { font-size: clamp(32px, 4.5vw, 52px); }
h2 { font-size: clamp(24px, 2.6vw, 32px); }
h3 { font-size: 19px; }
.wrap { width: min(1200px, 100% - 40px); margin-inline: auto; }
.kicker { display: inline-block; font-size: 12.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin: 0 0 8px; font-weight: 600; }
.lead { font-size: 18px; color: #4a443e; max-width: 680px; }
.small { font-size: 14px; color: var(--muted); }
.sub { font-family: var(--serif); font-style: italic; font-size: 19px; color: #4a443e; margin: 0 0 6px; }
.more { color: var(--accent); font-weight: 600; font-size: 15px; }
.more:hover { text-decoration: underline; }

/* Intestazione */
.top { background: rgba(246,242,236,.94); backdrop-filter: blur(6px); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 72px; flex-wrap: wrap; padding: 8px 0; }
.logo { display: flex; align-items: center; gap: 12px; }
.logo .mark { width: 34px; height: 34px; border-radius: 7px; background: var(--accent); position: relative; flex: none; }
.logo .mark::after { content: ""; position: absolute; inset: 9px; border: 3px solid #fff; }
.logo b { display: block; font-family: var(--serif); font-weight: 400; font-size: 22px; line-height: 1.1; }
.logo small { display: block; color: var(--muted); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
nav { display: flex; gap: 4px; flex-wrap: wrap; align-items: center; }
nav a { padding: 8px 14px; border-radius: 20px; font-size: 15px; }
nav a:hover { background: #ebe4da; }
nav a.on { background: var(--ink); color: #fff; }
nav a.cart { border: 1px solid var(--line); background: #fff; }
nav a.cart.on { background: var(--ink); }
nav a.cart b { display: inline-block; min-width: 22px; padding: 0 6px; margin-left: 4px; border-radius: 11px; background: var(--accent); color: #fff; font-size: 12.5px; text-align: center; }

/* Pulsanti */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 22px; border-radius: 8px; background: var(--accent); color: #fff; font: 600 15px var(--sans); border: 1px solid var(--accent); cursor: pointer; transition: background .15s; }
.btn:hover { background: var(--accent-dark); }
.btn.ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { background: #f1ebe3; }
.btn.wide { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.paypal { background: #ffc439; border-color: #ffc439; color: #1e2a55; width: 100%; }
.btn.paypal:hover { background: #f2b52a; }
.btn.added { background: var(--green); border-color: var(--green); }

/* Prima pagina */
.hero { padding: 56px 0 40px; }
.hero-in > *, .detail > *, .feature > *, .two > *, .cart-layout > *, .steps > *, .cols > * { min-width: 0; }
.hero-in { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 26px 0; }
.facts { display: flex; gap: 32px; list-style: none; padding: 0; margin: 0; color: var(--muted); }
.facts b { display: block; font: 400 30px var(--serif); color: var(--ink); }
.wall { background: var(--wall); border-radius: 14px; padding: 36px; display: flex; justify-content: center; align-items: center; }
.wall img { box-shadow: 0 18px 40px rgba(40,30,20,.28), 0 2px 6px rgba(40,30,20,.2); max-height: 520px; width: auto; border: 8px solid #fff; }
.wall.big img { max-height: 640px; }
.caption { display: flex; justify-content: space-between; gap: 12px; color: var(--muted); font-size: 15px; margin: 12px 4px 0; }
.caption .l { min-width: 0; font-weight: 400; color: var(--muted); white-space: normal; }
.caption b { color: var(--ink); font-family: var(--serif); font-weight: 400; font-size: 17px; }
.caption span { color: var(--ink); font-weight: 600; white-space: nowrap; }
.hero-art:hover .caption b { color: var(--accent); }

.block { margin: 56px auto; }
.head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 20px; }
.head h2 { margin: 0; }
.page-head { padding: 44px 0 20px; }
.crumbs { padding-top: 22px; font-size: 14px; color: var(--muted); }

/* Mostra in evidenza */
.feature { display: grid; grid-template-columns: 1fr 1fr; background: #fff; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; margin: 24px 0; transition: box-shadow .2s; }
.feature:hover { box-shadow: 0 10px 30px rgba(40,30,20,.12); }
.feature-img { min-height: 320px; background: var(--wall); }
.feature-img img { width: 100%; height: 100%; object-fit: cover; }
.feature-text { padding: 36px 40px; }
.dates { font-size: 14px; color: var(--muted); margin: 0 0 12px; }
.fase { display: inline-block; font-size: 12.5px; font-weight: 600; padding: 4px 12px; border-radius: 14px; margin-bottom: 12px; }
.fase.in-corso { background: var(--green-bg); color: var(--green); }
.fase.prossima { background: var(--amber-bg); color: var(--amber); }
.fase.conclusa { background: #ece7df; color: var(--muted); }

/* Griglia delle opere */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 24px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; transition: transform .15s, box-shadow .15s; display: flex; flex-direction: column; }
.card:hover { transform: translateY(-3px); box-shadow: 0 12px 28px rgba(40,30,20,.12); }
.card .frame { background: var(--wall); height: 250px; display: flex; align-items: center; justify-content: center; padding: 22px; position: relative; }
.card .frame img { max-height: 100%; max-width: 100%; width: auto; object-fit: contain; box-shadow: 0 8px 18px rgba(40,30,20,.25); border: 4px solid #fff; }
.card .info { padding: 14px 16px 16px; }
.card h3 { margin: 0 0 2px; font-size: 18px; }
.card .who { margin: 0; color: #4a443e; font-size: 14.5px; }
.card .meta { margin: 2px 0 8px; color: var(--muted); font-size: 13px; }
.card .price { margin: 0; font-weight: 700; }
.badge { position: absolute; top: 12px; left: 12px; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 12px; }
.badge.venduta, .pill.venduta { background: var(--red-bg); color: var(--red); }
.badge.riservata, .pill.riservata { background: var(--amber-bg); color: var(--amber); }
.pill { font-size: 13px; font-weight: 600; padding: 3px 12px; border-radius: 12px; }
.pill.disponibile { background: var(--green-bg); color: var(--green); }

/* Filtri */
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.filters input[type=search] { flex: 1 1 220px; }
input, select, textarea { font: 15px var(--sans); color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 9px 12px; width: 100%; }
.filters select { width: auto; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
label { display: block; font-size: 13.5px; color: var(--muted); margin-bottom: 12px; }
label input, label textarea, label select { margin-top: 4px; }
label.check { display: flex; align-items: center; gap: 8px; color: var(--ink); font-size: 15px; margin: 0; }
label.check input { width: auto; margin: 0; }
fieldset { border: 1px solid var(--line); border-radius: 8px; padding: 10px 14px; margin: 0 0 12px; display: grid; gap: 8px; }
legend { font-size: 13.5px; color: var(--muted); padding: 0 4px; }
.count { color: var(--muted); font-size: 14px; margin: 16px 0; }
.empty { text-align: center; color: var(--muted); padding: 40px 0; }

/* Scheda opera */
.detail { display: grid; grid-template-columns: 1.25fr .75fr; gap: 48px; align-items: start; margin-top: 18px; }
.detail .wall { padding: 56px; min-height: 480px; }
.detail-text h1 { margin-bottom: 0; }
.year { color: var(--muted); font-family: var(--serif); font-size: 20px; margin: 4px 0 18px; }
dl { display: grid; grid-template-columns: 90px 1fr; gap: 8px 12px; margin: 0 0 18px; font-size: 15px; }
dt { color: var(--muted); }
dd { margin: 0; }
.big-price { font: 400 34px var(--serif); margin: 6px 0 14px; }
.note { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--amber); border-radius: 8px; padding: 12px 14px; font-size: 15px; }
.text { margin-top: 18px; color: #4a443e; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 48px; }
.box { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 28px; }
.box h2 { font-size: 24px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.who-row { display: flex; gap: 14px; align-items: center; margin-bottom: 12px; }
.who-row h2, .who-row h3 { margin: 0; }
.who-row .kicker { margin: 0; }
.avatar { width: 56px; height: 56px; border-radius: 50%; color: #fff; display: inline-flex; align-items: center; justify-content: center; font: 400 21px var(--serif); flex: none; }
.avatar.big { width: 112px; height: 112px; font-size: 40px; }

/* Artisti */
.artists { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.artist-chip { display: flex; gap: 14px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 40px 12px 12px 40px; padding: 10px 16px 10px 10px; }
.artist-chip:hover { border-color: var(--accent); }
.artist-chip b { display: block; font-family: var(--serif); font-weight: 400; font-size: 18px; }
.artist-chip small { color: var(--muted); font-size: 13px; }
.artist-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 24px; margin-bottom: 56px; }
.artist-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px; transition: box-shadow .15s; }
.artist-card:hover { box-shadow: 0 12px 28px rgba(40,30,20,.12); }
.artist-card p { color: #4a443e; font-size: 15px; }
.thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; background: var(--wall); border-radius: 10px; padding: 14px; margin-bottom: 16px; height: 140px; }
.thumbs img { width: 100%; height: 100%; object-fit: cover; border: 3px solid #fff; box-shadow: 0 4px 10px rgba(40,30,20,.2); }
.artist-head { display: flex; gap: 32px; align-items: center; padding: 30px 0 10px; }
.artist-head h1 { margin: 0; }

/* Passi */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.steps > div { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 26px; }
.steps span { display: inline-flex; width: 38px; height: 38px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); align-items: center; justify-content: center; font: 400 20px var(--serif); margin-bottom: 12px; }
.steps p { color: #4a443e; margin: 0; }
.list { padding-left: 20px; color: #4a443e; }
.list li { margin-bottom: 8px; }

/* Carrello */
.cart-layout { display: grid; grid-template-columns: 1.3fr .9fr; gap: 32px; align-items: start; margin-bottom: 64px; }
.line { display: grid; grid-template-columns: 110px 1fr auto; gap: 18px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin-bottom: 12px; }
.line .pic { background: var(--wall); border-radius: 8px; height: 100px; display: flex; align-items: center; justify-content: center; padding: 10px; }
.line .pic img { max-height: 100%; width: auto; border: 3px solid #fff; }
.line h3 { margin: 0; }
.line p { margin: 0; font-size: 14px; color: var(--muted); }
.line .right { text-align: right; }
.line .right b { display: block; font-size: 17px; }
.line button { background: none; border: 0; color: var(--accent); cursor: pointer; font: 14px var(--sans); padding: 4px 0; }
.line.unavailable { opacity: .6; }
.sum { display: grid; grid-template-columns: 1fr auto; gap: 6px; margin: 16px 0; padding-top: 14px; border-top: 1px solid var(--line); }
.sum .tot { font: 400 24px var(--serif); }
.bank { background: var(--bg); border-radius: 8px; padding: 12px 14px; margin-top: 14px; font-size: 14.5px; }
.bank h4 { margin: 0 0 4px; }
.bank p { margin: 0; }
.ok { background: var(--green-bg); color: var(--green); border-radius: 8px; padding: 12px 14px; font-size: 14.5px; }

/* Piè di pagina */
.bottom { background: #1e1b18; color: #d8d0c6; padding: 48px 0 24px; margin-top: 72px; font-size: 15px; }
.bottom .cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 32px; }
.bottom h4 { color: #fff; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; margin: 0 0 12px; }
.bottom a { display: block; color: #d8d0c6; margin-bottom: 6px; }
.bottom p a { display: inline; color: #f0b79f; }
.bottom a:hover { color: #fff; }
.flogo { font: 400 22px var(--serif); color: #fff; }
.legal { border-top: 1px solid #3a352f; margin-top: 32px; padding-top: 18px; font-size: 13px; color: #9a9188; }

/* Schermi piccoli */
@media (max-width: 900px) {
  .hero-in, .feature, .detail, .two, .cart-layout, .steps { grid-template-columns: 1fr; }
  .hero { padding-top: 32px; }
  .feature-text { padding: 26px; }
  .detail .wall { padding: 28px; min-height: 0; }
  .bottom .cols { grid-template-columns: 1fr 1fr; }
  .artist-head { flex-direction: column; align-items: flex-start; gap: 16px; }
}
@media (max-width: 560px) {
  .nav { justify-content: center; }
  nav { justify-content: center; }
  nav a { padding: 6px 10px; font-size: 14px; }
  .row, .bottom .cols { grid-template-columns: 1fr; }
  .line { grid-template-columns: 80px 1fr; }
  .line .right { grid-column: 1 / -1; text-align: left; }
  .filters select { width: 100%; }
}
