/* Atelier Zagara — inviti di nozze animati in acquerello
   Linguaggio: atelier di cartoleria — carta calda, inchiostro, filo d'oro, ceralacca. */

@font-face { font-family: "Great Vibes"; src: url("../fonts/Great_Vibes-400.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../fonts/Cormorant_Garamond-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../fonts/Cormorant_Garamond-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url("../fonts/Montserrat-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url("../fonts/Montserrat-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Playfair Display"; src: url("../fonts/Playfair_Display-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Amiri"; src: url("../fonts/Amiri-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Amiri"; src: url("../fonts/Amiri-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --paper: #f6f0e2;
  --paper-deep: #efe6d2;
  --card: #fbf7ec;
  --card-edge: #e4d9bf;
  --ink: #3d372b;
  --ink-soft: #7a7260;
  --gold: #a8834b;
  --gold-soft: #c9ad7e;
  --wax: #7a2e2e;
  --wax-deep: #632424;
  --sage: #7a8471;
  --serif: "Cormorant Garamond", "Amiri", serif;
  --sans: "Montserrat", "Amiri", sans-serif;
  --script: "Great Vibes", cursive;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans); font-weight: 400; font-size: 16px;
  color: var(--ink); background: var(--paper);
  background-image:
    radial-gradient(ellipse 90% 55% at 50% -8%, #fdf9ef 0%, transparent 62%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='.035'/%3E%3C/svg%3E");
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
::selection { background: rgba(168, 131, 75, .28); }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 2px; }

/* ————— arabo: Amiri, MAI letter-spacing sulle legature ————— */
[dir="rtl"] body, body.lang-ar { font-family: "Amiri", var(--sans); }
body.lang-ar .serif-t, body.lang-ar h1, body.lang-ar h2, body.lang-ar h3 { font-family: "Amiri", serif; }
body.lang-ar .caps, body.lang-ar .eyebrow, body.lang-ar .strip, body.lang-ar .vcap,
body.lang-ar label, body.lang-ar .btn, body.lang-ar footer, body.lang-ar .lang button
  { letter-spacing: 0 !important; text-transform: none !important; }
body.lang-ar { font-size: 17.5px; }

/* ————— header ————— */
header.top {
  position: absolute; top: 0; left: 0; right: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 30px;
}
.brand-mini { font-family: var(--script); font-size: 27px; line-height: 1; text-decoration: none; }
.lang { display: flex; align-items: center; gap: 4px; }
.lang button {
  background: none; border: 0; cursor: pointer; font-family: var(--sans);
  font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-soft);
  padding: 6px 7px; border-bottom: 1px solid transparent; transition: color .15s, border-color .15s;
}
.lang button:hover { color: var(--ink); }
.lang button[aria-pressed="true"] { color: var(--wax); border-bottom-color: var(--gold); }
.lang .dot { color: var(--gold-soft); font-size: 11px; }

/* ————— hero ————— */
.hero { position: relative; padding: 128px 26px 84px; }
.hero-in {
  max-width: 1140px; margin: 0 auto; display: grid;
  grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center;
}
.hero-copy { max-width: 560px; }
.brand-hero {
  font-family: var(--script); font-weight: 400;
  font-size: clamp(58px, 8.5vw, 96px); line-height: 1.06;
  /* la mask clippa il paint al border-box: padding = aria per gli svolazzi, margin lo compensa */
  padding: .22em .34em .26em; margin: -.22em -.34em -.26em;
  -webkit-mask-image: linear-gradient(100deg, #000 0%, #000 42%, transparent 58%, transparent 100%);
  mask-image: linear-gradient(100deg, #000 0%, #000 42%, transparent 58%, transparent 100%);
  -webkit-mask-size: 260% 100%; mask-size: 260% 100%;
  -webkit-mask-position: 92% 0; mask-position: 92% 0;
  animation: writeon 2.4s cubic-bezier(.6,.05,.35,1) .35s forwards;
}
@keyframes writeon { to { -webkit-mask-position: 0% 0; mask-position: 0% 0; } }
[dir="rtl"] .brand-hero {
  -webkit-mask-image: linear-gradient(260deg, #000 0%, #000 42%, transparent 58%, transparent 100%);
  mask-image: linear-gradient(260deg, #000 0%, #000 42%, transparent 58%, transparent 100%);
}
.brand-hero.written { -webkit-mask-image: none !important; mask-image: none !important; animation: none; }
.brand-sub {
  font-size: 12px; letter-spacing: .5em; text-transform: uppercase; color: var(--gold);
  margin: 10px 0 26px; padding-left: .5em;
}
[dir="rtl"] .brand-sub { padding-left: 0; }
.hero h1 {
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(26px, 3.2vw, 38px); line-height: 1.25; margin-bottom: 16px;
}
.hero h1 em { font-style: italic; color: var(--wax); }
.hero .lead { font-size: 15.5px; line-height: 1.75; color: var(--ink-soft); max-width: 46ch; margin-bottom: 30px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin-bottom: 26px; }
.btn {
  display: inline-flex; align-items: center; gap: 9px; cursor: pointer; text-decoration: none;
  font-family: var(--sans); font-size: 12px; letter-spacing: .16em; text-transform: uppercase;
  padding: 15px 26px; border-radius: 2px; border: 1px solid transparent;
  transition: transform .15s, box-shadow .2s, background .2s, border-color .2s;
}
.btn-wax {
  background: var(--wax); color: #f8f0e4;
  box-shadow: 0 14px 30px -14px rgba(122, 46, 46, .55), 0 1px 0 rgba(255,255,255,.15) inset;
}
.btn-wax:hover { background: var(--wax-deep); transform: translateY(-1px); }
.btn-wax:active { transform: translateY(1px); }
.btn-line { border-color: var(--gold-soft); color: var(--ink); background: transparent; }
.btn-line:hover { background: rgba(168, 131, 75, .1); border-color: var(--gold); }
.btn svg { width: 15px; height: 15px; flex: 0 0 auto; }
.strip { font-size: 11.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-soft); }
.strip b { color: var(--gold); font-weight: 500; }

/* cornice cartoncino dei video */
.vcard { position: relative; background: var(--card); border: 1px solid var(--card-edge); border-radius: 3px;
  padding: 10px; box-shadow: 0 30px 70px -30px rgba(80, 62, 30, .5), 0 3px 10px rgba(80, 62, 30, .12);
  transition: transform .35s cubic-bezier(.2,.7,.3,1), box-shadow .35s;
}
.vcard::before { content: ""; position: absolute; inset: 5px; pointer-events: none;
  border: 1px solid rgba(168, 131, 75, .4); border-radius: 2px; z-index: 2; }
.vcard video { display: block; width: 100%; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 2px; background: var(--paper-deep); }
.vcard.tilt-l { transform: rotate(-1.6deg); }
.vcard.tilt-r { transform: rotate(1.2deg); }
.vcard:hover { transform: rotate(0deg) translateY(-5px); }
.hero-media { justify-self: center; width: min(340px, 82vw); }

/* ————— sezioni ————— */
section { padding: 92px 26px; }
.wrap { max-width: 1140px; margin: 0 auto; }
.sec-head { text-align: center; max-width: 640px; margin: 0 auto 56px; }
.eyebrow { font-size: 11px; letter-spacing: .5em; text-transform: uppercase; color: var(--gold); margin-bottom: 14px; padding-left: .5em; }
[dir="rtl"] .eyebrow { padding-left: 0; }
.sec-head h2 { font-family: var(--serif); font-weight: 600; font-size: clamp(30px, 4vw, 44px); line-height: 1.18; }
.sec-head .note { margin-top: 14px; font-size: 14.5px; line-height: 1.7; color: var(--ink-soft); }
.fleur { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 22px; }
.fleur::before, .fleur::after { content: ""; height: 1px; width: 84px;
  background: linear-gradient(90deg, transparent, var(--gold-soft)); }
.fleur::after { background: linear-gradient(270deg, transparent, var(--gold-soft)); }
.fleur svg { width: 20px; height: 20px; }

/* ————— demo ————— */
.demos { display: grid; grid-template-columns: .82fr 1.1fr 1.1fr .82fr; gap: 28px; align-items: center; }
.demos .demo:nth-child(4) { transition-delay: .44s; }
.demo { text-align: center; }
.demo .vwrap { position: relative; }
.playbtn {
  position: absolute; inset: 0; margin: auto; width: 76px; height: 76px; z-index: 3;
  border: 0; border-radius: 50%; cursor: pointer; background: rgba(122, 46, 46, .92);
  box-shadow: 0 16px 36px -10px rgba(60, 20, 20, .6), 0 0 0 7px rgba(248, 240, 228, .35);
  display: grid; place-items: center; transition: transform .2s, opacity .3s, background .2s;
}
.playbtn:hover { transform: scale(1.07); background: var(--wax-deep); }
.playbtn svg { width: 24px; height: 24px; fill: #f8f0e4; margin-left: 3px; }
[dir="rtl"] .playbtn svg { margin-left: 0; margin-right: 3px; }
.demo.playing .playbtn { opacity: 0; pointer-events: none; }
.vcap { margin-top: 16px; font-size: 11.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); line-height: 1.7; }
.vcap b { display: block; color: var(--gold); font-weight: 500; }

/* ————— galleria portfolio ————— */
.gal-note {
  margin: 64px auto 30px; text-align: center; max-width: 560px;
  font-family: var(--serif); font-style: italic; font-size: 19px; color: var(--ink-soft);
}
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.gitem { text-align: center; }
.gallery .gitem:nth-child(1) { transition-delay: .05s; }
.gallery .gitem:nth-child(2) { transition-delay: .15s; }
.gallery .gitem:nth-child(3) { transition-delay: .25s; }
.gallery .gitem:nth-child(4) { transition-delay: .35s; }
@media (max-width: 860px) {
  .gallery { grid-template-columns: 1fr 1fr; gap: 18px; }
  .gal-note { margin-top: 44px; }
}

/* ————— scena su misura ————— */
.custom-scene {
  margin: 60px auto 0; max-width: 640px; text-align: center;
  background: rgba(251, 247, 236, .65); border: 1.5px dashed var(--gold-soft); border-radius: 3px;
  padding: 42px 38px 40px;
}
.custom-scene .cs-ic { width: 42px; height: 42px; color: var(--gold); margin-bottom: 12px; }
.custom-scene h3 { font-family: var(--serif); font-weight: 600; font-size: 27px; margin-bottom: 10px; }
.custom-scene p { font-size: 14.5px; line-height: 1.8; color: var(--ink-soft); max-width: 50ch; margin: 0 auto 24px; }
@media (max-width: 860px) { .custom-scene { padding: 34px 24px 32px; margin-top: 44px; } }

/* ————— come funziona ————— */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.step { text-align: center; padding: 0 8px; }
.step .n { font-family: var(--serif); font-weight: 600; font-size: 58px; color: var(--gold-soft); line-height: 1; }
.step .ic { margin: 14px auto 16px; width: 46px; height: 46px; color: var(--ink-soft); }
.step .ic svg { width: 100%; height: 100%; }
.step h3 { font-family: var(--serif); font-weight: 600; font-size: 23px; margin-bottom: 10px; }
.step p { font-size: 14px; line-height: 1.75; color: var(--ink-soft); max-width: 34ch; margin: 0 auto; }
.privacy-note {
  margin: 54px auto 0; max-width: 560px; text-align: center;
  font-family: var(--serif); font-size: 19px; font-style: italic; color: var(--ink);
  padding: 20px 26px; border-top: 1px solid var(--gold-soft); border-bottom: 1px solid var(--gold-soft);
}
.privacy-note b { color: var(--wax); font-weight: 600; }

/* ————— prezzi: 3 tier ————— */
.tiers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; align-items: center; max-width: 1040px; margin: 0 auto; }
.tier {
  position: relative; background: var(--card); border: 1px solid var(--card-edge); border-radius: 3px;
  padding: 36px 28px 34px; text-align: center;
  box-shadow: 0 24px 56px -28px rgba(80, 62, 30, .4), 0 2px 8px rgba(80, 62, 30, .08);
}
.tier::before { content: ""; position: absolute; inset: 8px; pointer-events: none;
  border: 1px solid rgba(168, 131, 75, .32); border-radius: 2px; }
.tier h3 { font-family: var(--serif); font-weight: 600; font-size: 24px; }
.tier-num { font-family: "Playfair Display", var(--serif); font-weight: 600; font-size: 58px; line-height: 1.1; color: var(--ink); margin-top: 10px; }
.tier-num small { font-size: 30px; color: var(--gold); }
.tier .price-list { max-width: 260px; margin-top: 20px; }
.tier .price-list li { font-size: 13.5px; padding: 6px 0; }
.tier.featured {
  padding: 48px 32px 44px; border-color: var(--gold-soft);
  box-shadow: 0 36px 84px -32px rgba(80, 62, 30, .55), 0 3px 12px rgba(80, 62, 30, .12);
}
.tier.featured::before { border-color: rgba(168, 131, 75, .5); }
.tier.featured h3 { font-size: 28px; }
.tier.featured .tier-num { font-size: 84px; }
.tier.featured .tier-num small { font-size: 42px; }
.pick {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--wax); color: #f3e3cf; border-radius: 999px; padding: 7px 16px;
  font-size: 10px; letter-spacing: .28em; text-transform: uppercase; white-space: nowrap;
}
body.lang-ar .pick { letter-spacing: 0; font-size: 13px; }
.price-list { list-style: none; margin: 28px auto 0; max-width: 340px; text-align: start; }
.price-list li { display: flex; gap: 12px; align-items: baseline; font-size: 14.5px; line-height: 1.55; color: var(--ink); padding: 7px 0; }
.price-list li + li { border-top: 1px dashed rgba(168, 131, 75, .3); }
.price-list li::before { content: "—"; color: var(--gold); flex: 0 0 auto; }
.wax-seal {
  position: absolute; top: -34px; inset-inline-end: -26px; width: 104px; height: 104px; z-index: 3;
  display: grid; place-items: center; text-align: center; transform: rotate(11deg);
  background: radial-gradient(circle at 34% 30%, #8f3b3b, var(--wax) 55%, #5d2020);
  border-radius: 47% 53% 50% 50% / 55% 48% 52% 45%;
  box-shadow: 0 14px 30px -10px rgba(60, 20, 20, .55), inset 0 2px 6px rgba(255, 226, 200, .3), inset 0 -4px 10px rgba(40, 10, 10, .5);
  color: #f3e3cf; font-family: var(--serif); font-weight: 600;
}
.wax-seal span { display: block; font-size: 26px; line-height: 1; }
.wax-seal small { display: block; font-size: 9.5px; letter-spacing: .14em; text-transform: uppercase; margin-top: 3px; opacity: .85; }
.extras { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 34px; }
.chip {
  font-size: 12.5px; letter-spacing: .06em; color: var(--ink);
  background: #fffdf7; border: 1px solid var(--card-edge); border-radius: 999px; padding: 9px 18px;
}
.chip b { color: var(--wax); font-weight: 500; }
.tailor { margin-top: 26px; font-family: var(--serif); font-style: italic; font-size: 16.5px; color: var(--ink-soft); }

/* ————— partner ————— */
.partner { background: var(--paper-deep); border-top: 1px solid var(--gold-soft); border-bottom: 1px solid var(--gold-soft); }
.partner .wrap { max-width: 760px; text-align: center; }
.partner h2 { font-family: var(--serif); font-weight: 600; font-size: clamp(26px, 3.4vw, 36px); line-height: 1.25; margin-bottom: 16px; }
.partner p { font-size: 15px; line-height: 1.8; color: var(--ink-soft); max-width: 56ch; margin: 0 auto 30px; }
.partner p b { color: var(--ink); font-weight: 500; }

/* ————— contatti ————— */
.contact-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 54px; align-items: start; }
.contact-copy h2 { font-family: var(--serif); font-weight: 600; font-size: clamp(28px, 3.6vw, 40px); line-height: 1.2; margin-bottom: 16px; }
.contact-copy p { font-size: 15px; line-height: 1.8; color: var(--ink-soft); margin-bottom: 26px; }
.wa-side { display: inline-flex; }
form.sheet {
  background: var(--card); border: 1px solid var(--card-edge); border-radius: 3px; position: relative;
  padding: 34px 36px 38px; box-shadow: 0 26px 60px -28px rgba(80, 62, 30, .45), 0 2px 8px rgba(80, 62, 30, .1);
}
form.sheet::before { content: ""; position: absolute; inset: 8px; pointer-events: none;
  border: 1px solid rgba(168, 131, 75, .35); border-radius: 2px; }
.fgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; position: relative; z-index: 1; }
label { display: flex; flex-direction: column; gap: 6px; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); }
label.wide { grid-column: 1 / -1; }
input, select, textarea {
  font-family: var(--sans); font-size: 14.5px; color: var(--ink);
  background: #fffdf7; border: 1px solid #ddd0b2; border-radius: 2px; padding: 11px 13px;
  outline: none; transition: border-color .15s, box-shadow .15s; width: 100%;
}
body.lang-ar input, body.lang-ar select, body.lang-ar textarea { font-family: "Amiri", var(--sans); font-size: 16px; }
input:focus, select:focus, textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(168, 131, 75, .13); }
textarea { min-height: 108px; resize: vertical; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; padding: 0; }
.form-foot { grid-column: 1 / -1; display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: 6px; }
.form-msg { grid-column: 1 / -1; font-size: 14px; line-height: 1.6; display: none; }
.form-msg.ok { display: block; color: var(--sage); font-family: var(--serif); font-size: 18px; font-style: italic; }
.form-msg.err { display: block; color: var(--wax); }
.form-msg a { color: var(--wax); font-weight: 500; }

/* ————— footer ————— */
footer { text-align: center; padding: 58px 26px 44px; border-top: 1px solid rgba(168, 131, 75, .3); }
footer .zg { width: 30px; height: 30px; margin: 0 auto 16px; opacity: .8; }
footer .fbrand { font-family: var(--script); font-size: 30px; margin-bottom: 12px; }
footer p { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); line-height: 2.1; }
footer a { color: var(--ink-soft); text-decoration: none; border-bottom: 1px solid var(--gold-soft); padding-bottom: 1px; }
footer a:hover { color: var(--ink); }

/* ————— reveal ————— */
.rv { opacity: 0; transform: translateY(20px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.3,1); }
.rv.on { opacity: 1; transform: none; }
.demos .demo:nth-child(1), .steps .step:nth-child(1) { transition-delay: .05s; }
.demos .demo:nth-child(2), .steps .step:nth-child(2) { transition-delay: .18s; }
.demos .demo:nth-child(3), .steps .step:nth-child(3) { transition-delay: .31s; }

@media (prefers-reduced-motion: reduce) {
  .brand-hero { animation: none; -webkit-mask-image: none; mask-image: none; }
  .rv { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ————— responsive ————— */
@media (max-width: 980px) {
  .hero-in { grid-template-columns: 1fr; gap: 44px; text-align: center; }
  .hero-copy { max-width: 620px; margin: 0 auto; }
  .hero .lead { margin-left: auto; margin-right: auto; }
  .cta-row { justify-content: center; }
  .contact-grid { grid-template-columns: 1fr; gap: 36px; }
  .contact-copy { text-align: center; }
}
@media (max-width: 860px) {
  section { padding: 72px 22px; }
  .demos { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 22px;
    padding: 8px 6px 22px; margin: 0 -22px; padding-inline: 22px; scrollbar-width: none; }
  .demos::-webkit-scrollbar { display: none; }
  .demo { flex: 0 0 min(74vw, 320px); scroll-snap-align: center; }
  .steps { grid-template-columns: 1fr; gap: 44px; }
  .fgrid { grid-template-columns: 1fr; }
  .tiers { grid-template-columns: 1fr; max-width: 440px; gap: 34px; }
  .tier.featured { padding: 44px 26px 40px; }
  .wax-seal { inset-inline-end: -10px; top: -30px; width: 92px; height: 92px; }
  .wax-seal span { font-size: 23px; }
  header.top { padding: 16px 20px; }
  .brand-mini { font-size: 23px; }
  .hero { padding-top: 104px; }
}
