*{box-sizing:border-box}body{font:16px/1.55 system-ui,-apple-system,Segoe UI,sans-serif;background:#f7f9fc;color:#1b2433;margin:0}header{display:flex;justify-content:space-between;align-items:center;padding:18px max(18px,calc((100vw - 1050px)/2));background:white;border-bottom:1px solid #e4eaf0;gap:12px;flex-wrap:wrap}a{color:#1556b4;text-decoration:none}nav{display:flex;gap:14px;flex-wrap:wrap}.brand{font-weight:800;font-size:24px;color:#182438}.brand span{color:#2563eb}main{max-width:1050px;margin:32px auto;padding:0 18px;min-height:65vh}h1{font-size:clamp(28px,4vw,44px);line-height:1.17;margin:0 0 20px}h2{font-size:24px}.hero{padding:45px 0}.hero p{max-width:650px;font-size:19px;color:#526174}.pill{display:inline-block;background:#e4f4e9;color:#166534;border-radius:20px;padding:5px 13px;font-weight:700;margin-bottom:20px}.btn,button{display:inline-block;background:#2563eb;color:white;border:0;border-radius:10px;padding:12px 18px;font-size:16px;cursor:pointer;font-weight:650}.btn.secondary,button.secondary{background:#e8effc;color:#1b4b91}.btn.danger,button.danger{background:#a12b2b}.card,.property-block{background:white;border:1px solid #e1e8ef;border-radius:14px;padding:23px;margin:16px 0;box-shadow:0 2px 8px #1b243308}.narrow{max-width:570px}label{display:block;margin:15px 0;font-weight:600}input:not([type=checkbox]),select,textarea{display:block;width:100%;font:inherit;padding:11px;border:1px solid #b8c4d3;border-radius:8px;margin-top:5px}textarea{min-height:100px}.check{display:flex;align-items:center;gap:10px;font-weight:400}.check input{width:18px;height:18px}.hint,small{font-size:14px;color:#59677a}.notice{padding:15px;background:#e7f2ff;border-radius:10px;margin:15px 0}.error{background:#ffe9e9;padding:14px;border-radius:10px;color:#8d1616}.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(270px,1fr));gap:15px}.logo{max-height:95px;max-width:180px;object-fit:contain}.guest{border-top:1px solid #ddd;padding-top:18px;margin-top:18px}.actions{display:flex;flex-wrap:wrap;gap:10px;align-items:center}.data-table{width:100%;border-collapse:collapse}.data-table td,.data-table th{border-bottom:1px solid #e5eaf0;padding:10px;text-align:left;vertical-align:top;overflow-wrap:anywhere}footer{text-align:center;padding:30px;color:#64748b;font-size:13px}code{overflow-wrap:anywhere}input:focus,textarea:focus,select:focus{outline:2px solid #9dbefa}@media(max-width:650px){.card{padding:17px}.data-table{font-size:14px}}
/* Scelta colori: compatibile con la Content Security Policy, senza stili inline */
.color-picker{border:1px solid #dce4ef;border-radius:12px;padding:14px;margin:18px 0;min-width:0}
.color-picker legend{font-weight:700;padding:0 6px}
.color-options{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.color-choice{display:flex;flex-direction:column;align-items:center;gap:4px;margin:0;padding:9px 4px;border:2px solid transparent;border-radius:10px;cursor:pointer;font-size:13px;text-align:center}
.color-choice:has(input:checked){border-color:#243d60;background:#eef4ff}
.color-choice:focus-within{outline:2px solid #9dbefa}
.color-choice input[type=radio]{position:absolute;opacity:0;width:1px;height:1px;margin:0;padding:0}
.color-dot{display:flex;align-items:center;justify-content:center;width:42px;height:42px;border-radius:50%;box-shadow:0 1px 5px #0002}
.color-choice input:checked + .color-dot::after{content:'✓';font-size:24px;font-weight:800;color:white;text-shadow:0 1px 3px #0008}
.color-dot-0{background:#2563eb}.color-dot-1{background:#059669}.color-dot-2{background:#7c3aed}.color-dot-3{background:#ea580c}
.color-dot-4{background:#dc2626}.color-dot-5{background:#0f766e}.color-dot-6{background:#334155}.color-dot-7{background:#be185d}
.color-preview{border:1px solid #e2e8f0;background:#f8fafc;border-radius:10px;padding:12px;margin-top:12px;font-size:13px;color:#475569}
.color-preview-banner{padding:12px;border-radius:8px;color:white;background:#2563eb;font-weight:700;margin-top:7px}
.color-preview p{margin:8px 0 0}
.color-picker:has(input[value="#059669"]:checked) .color-preview-banner{background:#059669}
.color-picker:has(input[value="#7c3aed"]:checked) .color-preview-banner{background:#7c3aed}
.color-picker:has(input[value="#ea580c"]:checked) .color-preview-banner{background:#ea580c}
.color-picker:has(input[value="#dc2626"]:checked) .color-preview-banner{background:#dc2626}
.color-picker:has(input[value="#0f766e"]:checked) .color-preview-banner{background:#0f766e}
.color-picker:has(input[value="#334155"]:checked) .color-preview-banner{background:#334155}
.color-picker:has(input[value="#be185d"]:checked) .color-preview-banner{background:#be185d}
@media(max-width:450px){.color-options{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* Modulo ospiti su una pagina, con intestazione e foto responsive */
body:has(.pc-guest-card) main{max-width:760px;margin:20px auto}
.pc-guest-card{min-width:0;overflow:hidden;padding:clamp(15px,3.5vw,25px)}
.pc-property-heading{display:flex;align-items:center;gap:clamp(10px,3vw,20px);min-width:0;margin-bottom:16px}
.pc-property-heading .logo{display:block;flex:0 0 auto;width:auto;max-width:clamp(65px,22vw,120px);max-height:clamp(65px,22vw,105px);object-fit:contain}
.pc-property-heading h1{flex:1;min-width:0;overflow-wrap:anywhere;font-size:clamp(21px,5vw,34px);line-height:1.2;margin:0;text-align:left}
.pc-property-photo{display:block;width:100%;max-width:100%;height:clamp(130px,36vw,245px);object-fit:cover;object-position:center;border-radius:12px;margin:0 0 20px}
.pc-form-title{font-size:clamp(22px,4.5vw,27px);margin:10px 0}
.pc-guest-card input:focus,.pc-guest-card select:focus,.pc-guest-card textarea:focus{outline:2px solid var(--pc-accent,#059669)}
@media(max-width:450px){.pc-property-heading{gap:10px}.pc-property-heading .logo{max-width:75px;max-height:75px}.pc-property-photo{height:155px}}

/* Colore scelto dal gestore: classi CSS compatibili con CSP style-src self */
.pc-guest-card.pc-accent-0{--pc-accent:#2563eb;border-top:6px solid #2563eb}
.pc-guest-card.pc-accent-1{--pc-accent:#059669;border-top:6px solid #059669}
.pc-guest-card.pc-accent-2{--pc-accent:#7c3aed;border-top:6px solid #7c3aed}
.pc-guest-card.pc-accent-3{--pc-accent:#ea580c;border-top:6px solid #ea580c}
.pc-guest-card.pc-accent-4{--pc-accent:#dc2626;border-top:6px solid #dc2626}
.pc-guest-card.pc-accent-5{--pc-accent:#0f766e;border-top:6px solid #0f766e}
.pc-guest-card.pc-accent-6{--pc-accent:#334155;border-top:6px solid #334155}
.pc-guest-card.pc-accent-7{--pc-accent:#be185d;border-top:6px solid #be185d}

.pc-guest-card .pc-form-title,.pc-guest-card .guest>h2{color:var(--pc-accent,#2563eb)}
.pc-guest-card button[type="submit"]{background:var(--pc-accent,#2563eb);color:#fff}
.pc-guest-card details summary{color:var(--pc-accent,#2563eb);cursor:pointer}
.pc-guest-card input:focus,.pc-guest-card select:focus,.pc-guest-card textarea:focus{outline:2px solid var(--pc-accent,#2563eb);outline-offset:1px}

/* Selettore lingua sempre visibile anche su smartphone */
.pc-lang{margin:0 0 12px;display:flex;justify-content:flex-end}
.pc-language-buttons{display:flex;align-items:center;gap:7px;flex-wrap:wrap;justify-content:flex-end}
.pc-language-buttons button{width:45px;height:43px;display:inline-flex;align-items:center;justify-content:center;padding:0;background:#fff;border:1px solid #cbd5e1;border-radius:10px;font-size:25px;line-height:1;box-shadow:none;color:inherit}
.pc-language-buttons button[aria-pressed="true"]{border:2px solid #2563eb;background:#eff6ff}
.pc-language-buttons button:focus-visible{outline:3px solid #2563eb;outline-offset:2px}
.pc-visually-hidden{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
@media(max-width:450px){.pc-lang{justify-content:center}.pc-language-buttons{gap:5px}.pc-language-buttons button{width:44px;height:42px}}

/* Personalizzazione modulo ospiti: accento applicato anche a lingua e navigazione */
.pc-lang.pc-accent-0{--pc-accent:#2563eb}
.pc-lang.pc-accent-1{--pc-accent:#059669}
.pc-lang.pc-accent-2{--pc-accent:#7c3aed}
.pc-lang.pc-accent-3{--pc-accent:#ea580c}
.pc-lang.pc-accent-4{--pc-accent:#dc2626}
.pc-lang.pc-accent-5{--pc-accent:#0f766e}
.pc-lang.pc-accent-6{--pc-accent:#334155}
.pc-lang.pc-accent-7{--pc-accent:#be185d}
.pc-language-buttons button[aria-pressed="true"]{border-color:var(--pc-accent,#2563eb);background:#fff;box-shadow:0 0 0 1px var(--pc-accent,#2563eb)}
.pc-language-buttons button:focus-visible{outline-color:var(--pc-accent,#2563eb)}
.pc-language-buttons button img{display:block;width:29px;height:20px;object-fit:cover;border-radius:2px;box-shadow:0 0 0 1px #0002}
body:has(.pc-guest-card) .brand span{color:var(--pc-header-accent,#2563eb)}
body:has(.pc-guest-card) .pc-property-heading h1{color:var(--pc-accent,#2563eb)}
body:has(.pc-guest-card) .pc-guest-card{border-top-width:6px}
.grid .card > img {
    display: block;
    margin-left: auto;
    margin-right: auto;
}