/* =============================================================================
   styles.css — Design system Adamo Apartments
   Palette neutra calda (sabbia/greige/avorio) + accento tematizzabile.
   Tutto via variabili CSS: cambiando --accent o i font si ri-veste il sito.
   ============================================================================= */

:root {
  /* Neutri caldi */
  --ivory:    oklch(0.975 0.008 85);   /* sfondo pagina */
  --paper:    oklch(0.992 0.005 85);   /* card / superfici chiare */
  --sand:     oklch(0.945 0.012 78);   /* superfici alternate */
  --greige:   oklch(0.885 0.014 72);   /* bordi morbidi */
  --greige-2: oklch(0.80 0.016 70);    /* bordi più marcati */
  --ink:      oklch(0.26 0.012 60);    /* testo principale, near-black caldo */
  --ink-soft: oklch(0.42 0.012 62);    /* testo secondario */
  --muted:    oklch(0.55 0.012 65);    /* testo tenue / didascalie */

  /* Accento (default: verde bosco). Sovrascrivibile da [data-accent] / Tweaks */
  --accent:        oklch(0.43 0.055 158);
  --accent-deep:   oklch(0.35 0.05 158);
  --accent-soft:   oklch(0.93 0.02 158);
  --accent-contrast: oklch(0.985 0.005 158);

  /* Tipografia */
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Hanken Grotesk", system-ui, sans-serif;

  /* Forme */
  --radius: 4px;
  --radius-lg: 10px;
  --radius-xl: 18px;
  --shadow-sm: 0 1px 2px oklch(0.26 0.012 60 / 0.06), 0 2px 6px oklch(0.26 0.012 60 / 0.04);
  --shadow-md: 0 4px 14px oklch(0.26 0.012 60 / 0.08), 0 12px 36px oklch(0.26 0.012 60 / 0.07);
  --shadow-lg: 0 18px 60px oklch(0.26 0.012 60 / 0.16);

  /* Layout */
  --maxw: 1200px;
  --gutter: clamp(20px, 5vw, 64px);
  --section-y: clamp(64px, 9vw, 132px);
}

/* Varianti accento (usate dal Tweaks panel via data-accent sull'html) */
html[data-accent="ottanio"] {
  --accent:        oklch(0.48 0.07 215);
  --accent-deep:   oklch(0.40 0.065 215);
  --accent-soft:   oklch(0.93 0.025 215);
  --accent-contrast: oklch(0.985 0.005 215);
}
html[data-accent="terracotta"] {
  --accent:        oklch(0.56 0.11 42);
  --accent-deep:   oklch(0.48 0.10 42);
  --accent-soft:   oklch(0.93 0.03 50);
  --accent-contrast: oklch(0.99 0.005 50);
}

/* Varianti display font */
html[data-display="fraunces"] { --font-display: "Fraunces", Georgia, serif; }
html[data-display="sans"]     { --font-display: "Hanken Grotesk", system-ui, sans-serif; }

* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: var(--font-body);
  background: var(--ivory);
  color: var(--ink);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 500; line-height: 1.08; letter-spacing: -0.01em; color: var(--ink); }

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
img { display: block; max-width: 100%; }

::selection { background: var(--accent); color: var(--accent-contrast); }

/* ---- Util ---------------------------------------------------------------- */
.wrap { max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.eyebrow {
  font-family: var(--font-body); font-size: 12px; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--accent-deep);
  display: inline-flex; align-items: center; gap: 10px;
}
.eyebrow::before { content: ""; width: 26px; height: 1px; background: var(--accent); display: inline-block; }
.section-title { font-size: clamp(30px, 4.6vw, 52px); }
.lede { font-size: clamp(17px, 1.6vw, 20px); color: var(--ink-soft); max-width: 56ch; text-wrap: pretty; }

/* ---- Bottoni ------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--font-body); font-weight: 600; font-size: 15px; letter-spacing: 0.01em;
  padding: 14px 26px; border-radius: var(--radius); cursor: pointer;
  transition: transform .18s ease, background .2s ease, box-shadow .2s ease, color .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-contrast); box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--accent-deep); box-shadow: var(--shadow-md); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--greige-2); }
.btn-ghost:hover { border-color: var(--ink); background: var(--paper); }
.btn-light { background: var(--paper); color: var(--ink); box-shadow: var(--shadow-sm); }
.btn-light:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.btn-block { width: 100%; }

/* ---- Placeholder fotografico (stripe + etichetta mono) ------------------- */
.ph {
  position: relative; overflow: hidden; background: var(--sand);
  background-image: repeating-linear-gradient(135deg,
    transparent 0 13px,
    oklch(0.85 0.014 72 / 0.55) 13px 14px);
  display: flex; align-items: flex-end; color: var(--ink-soft);
}
.ph::after {
  content: attr(data-label);
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 11px; letter-spacing: 0.04em; text-transform: lowercase;
  background: var(--paper); color: var(--muted);
  padding: 5px 9px; margin: 12px; border-radius: 3px; box-shadow: var(--shadow-sm);
}

/* ---- Scroll reveal ------------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
