/*
Theme Name:    Marligure
Theme URI:     https://hotelmarligure.it/
Description:   Editorial guide theme for recovered Italian travel domains. First instance: hotelmarligure.it.
Author:        Marco Bianchi
Author URI:    https://hotelmarligure.it/chi-sono/
Version:       1.0.0
License:       GPL-2.0-or-later
Text Domain:   marligure
*/

/* ---------- Reset (small) ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; }
img, picture, svg { max-width: 100%; height: auto; display: block; }

/* ---------- Tokens ---------- */
:root {
  --bg:          #FBF8F1;
  --surface:    #FFFFFF;
  --border:     #E8E0CE;
  --primary:    #1B4458;
  --primary-hi: #2A6A89;
  --accent:     #C7704A;
  --text:       #2A2A2A;
  --muted:      #6B6B6B;
  --rule:       #D8CFB8;

  --serif: "Cormorant Garamond", "Cormorant", "Lora", Georgia, "Times New Roman", serif;
  --sans:  "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono:  ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --measure: 38rem;   /* ~610px reading column */
  --gutter: 1.25rem;
}

/* ---------- Base ---------- */
html { font-size: 17px; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.18;
  color: var(--primary);
  margin: 0 0 0.6em;
  letter-spacing: -0.005em;
}
h1 { font-size: clamp(1.95rem, 2.8vw + 1rem, 2.75rem); }
h2 { font-size: clamp(1.55rem, 1.5vw + 1rem, 1.95rem); margin-top: 2.2em; }
h3 { font-size: 1.3rem; margin-top: 1.8em; color: var(--text); }
h4 { font-size: 1.05rem; color: var(--text); font-weight: 600; font-family: var(--sans); }
p  { margin: 0 0 1em; }
strong { font-weight: 600; }
em { font-style: italic; }

a {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color .15s ease;
}
a:hover { color: var(--accent); }

ul, ol {
  padding-left: 1.4em;
  margin: 0 0 1.1em;
}
li { margin-bottom: .35em; }

hr {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 2.6em 0;
}

blockquote {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--muted);
  border-left: 3px solid var(--accent);
  padding: .2em 0 .2em 1.2em;
  margin: 1.5em 0;
}

code, kbd {
  font-family: var(--mono);
  font-size: .92em;
  background: rgba(199, 112, 74, 0.08);
  padding: 0.1em 0.35em;
  border-radius: 3px;
}

table {
  border-collapse: collapse;
  width: 100%;
  margin: 1.5em 0;
  font-size: .94rem;
}
th, td {
  text-align: left;
  padding: .55em .8em;
  border-bottom: 1px solid var(--border);
}
th { color: var(--primary); font-weight: 600; }

/* ---------- Layout ---------- */
.container { max-width: var(--measure); margin-inline: auto; padding-inline: var(--gutter); }
.wide      { max-width: 70rem; margin-inline: auto; padding-inline: var(--gutter); }

main { padding: 2.5rem 0 4rem; }
article > * + * { margin-top: 0; }

/* ---------- Header ---------- */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: saturate(180%) blur(8px);
  -webkit-backdrop-filter: saturate(180%) blur(8px);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  max-width: 70rem;
  margin-inline: auto;
  padding: .9rem var(--gutter);
}
.brand {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
  text-decoration: none;
}
.brand__name {
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--primary);
  letter-spacing: -.01em;
}
.brand__tagline {
  font-size: .68rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
  font-weight: 500;
}

.nav-primary {
  display: flex;
  align-items: center;
  gap: 1.4rem;
}
.nav-primary ul {
  display: flex;
  gap: 1.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.nav-primary li { margin: 0; }
.nav-primary a {
  font-size: .82rem;
  font-weight: 500;
  letter-spacing: .04em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text);
  padding: .4em 0;
  border-bottom: 1.5px solid transparent;
}
.nav-primary a:hover,
.nav-primary .current-menu-item a {
  color: var(--primary);
  border-bottom-color: var(--accent);
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  font-size: .78rem;
  letter-spacing: .12em;
  font-weight: 600;
}
.lang-switch a, .lang-switch span {
  display: inline-block;
  padding: .25em .5em;
  text-decoration: none;
  color: var(--muted);
  border-radius: 3px;
}
.lang-switch .active {
  background: var(--primary);
  color: var(--surface);
}
.lang-switch a:hover { color: var(--primary); }

.nav-toggle {
  display: none;
  border: 0;
  background: transparent;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--primary);
  padding: .25em .4em;
}

@media (max-width: 760px) {
  .nav-toggle { display: inline-block; }
  .nav-primary { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--surface); border-bottom: 1px solid var(--border); padding: 1rem var(--gutter); flex-direction: column; align-items: stretch; gap: 0; }
  .nav-primary.is-open { display: flex; }
  .nav-primary ul { flex-direction: column; gap: .9rem; }
  .nav-primary a { padding: .3em 0; }
  .lang-switch { margin-top: .8rem; padding-top: .8rem; border-top: 1px solid var(--border); justify-content: flex-start; }
}

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(120% 80% at 20% 10%, rgba(199,112,74,0.06), transparent 60%),
    linear-gradient(180deg, #DDE4E2 0%, #B8C9CD 55%, #91A8B0 100%);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: .35;
}
.hero__inner {
  max-width: 50rem;
  margin-inline: auto;
  padding: 4rem var(--gutter) 3rem;
  text-align: center;
}
.hero__eyebrow {
  display: inline-block;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 1.2rem;
  padding: .35em .9em;
  background: rgba(255, 255, 255, 0.55);
  border-radius: 999px;
}
.hero__title {
  font-family: var(--serif);
  font-size: clamp(2.5rem, 4.5vw + 1rem, 4rem);
  color: #163844;
  margin: 0 0 .35em;
  letter-spacing: -.015em;
  font-weight: 500;
}
.hero__sub {
  font-size: 1.05rem;
  color: #284E5E;
  max-width: 36rem;
  margin: 0 auto;
}
.hero__notice {
  margin: 2rem auto 0;
  max-width: 38rem;
  padding: 1rem 1.25rem;
  background: rgba(255, 255, 255, 0.75);
  border-left: 3px solid var(--accent);
  text-align: left;
  font-size: .95rem;
  color: #1A1A1A;
}

.hero--image {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: #fff;
}
.hero--image .hero__eyebrow {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  backdrop-filter: blur(4px);
}
.hero--image .hero__title { color: #fff; text-shadow: 0 2px 24px rgba(0,0,0,.35); }
.hero--image .hero__sub   { color: rgba(255,255,255,.92); }
.hero--image .hero__notice {
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  border-left-color: var(--accent);
  backdrop-filter: blur(4px);
}
.hero--image::after { background: linear-gradient(90deg, transparent, rgba(255,255,255,.5), transparent); }

.page-hero-image {
  max-width: 64rem;
  margin: 0 auto 2.5rem;
  padding-inline: var(--gutter);
}
.page-hero-image__img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 4px;
  box-shadow: 0 2px 16px rgba(20,40,60,.08);
}
.page-hero-image__cap {
  margin-top: .6rem;
  font-size: .85rem;
  color: var(--muted, #6b6b6b);
  text-align: center;
  font-style: italic;
}

/* Hotel listing block */
.hotel-list { list-style: none; padding: 0; margin: 1.5rem 0; counter-reset: hl; }
.hotel-list > li {
  position: relative;
  padding: 1.1rem 1.25rem 1.1rem 3rem;
  margin-bottom: .9rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
  counter-increment: hl;
}
.hotel-list > li::before {
  content: counter(hl);
  position: absolute;
  left: 1rem;
  top: 1.1rem;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  text-align: center;
  line-height: 1.6rem;
  font-size: .85rem;
  font-weight: 600;
}
.hotel-list > li strong { color: var(--primary); }
.hotel-meta {
  display: block;
  margin-top: .35rem;
  color: #555;
  font-size: .92rem;
  font-variant-numeric: tabular-nums;
}

/* FAQ block */
.faq { margin: 1.5rem 0 2rem; }
.faq details {
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0 1.1rem;
  margin-bottom: .55rem;
  background: var(--surface);
}
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: .95rem 0;
  font-size: 1rem;
  position: relative;
  padding-right: 2rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.4rem;
  color: var(--accent);
  font-weight: 300;
  transition: transform .15s ease;
}
.faq details[open] summary::after { content: "−"; }
.faq details > p { padding-bottom: 1rem; margin: 0; color: #2a2a2a; }

.facts-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.fact {
  text-align: center;
  padding: 1.4rem 1rem;
  border-right: 1px solid var(--border);
}
.fact:last-child { border-right: 0; }
.fact__value {
  font-family: var(--serif);
  font-size: 1.6rem;
  color: var(--primary);
  display: block;
  line-height: 1.1;
}
.fact__label {
  display: block;
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: .25rem;
}
@media (max-width: 760px) {
  .facts-strip { grid-template-columns: repeat(2, 1fr); }
  .fact { border-bottom: 1px solid var(--border); }
  .fact:nth-child(2) { border-right: 0; }
}

/* ---------- Card grid ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin: 3rem 0;
}
.cards--two { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1.5rem 1.4rem;
  text-decoration: none;
  color: var(--text);
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 8px 28px -10px rgba(27, 68, 88, 0.18);
}
.card__eyebrow {
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: .4rem;
}
.card__title {
  font-family: var(--serif);
  font-size: 1.35rem;
  color: var(--primary);
  margin: 0 0 .5rem;
  line-height: 1.15;
}
.card__desc {
  color: var(--muted);
  font-size: .94rem;
  margin: 0 0 1rem;
  flex: 1;
}
.card__cta {
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--accent);
}
.card__cta::after { content: " →"; }

@media (max-width: 760px) {
  .cards, .cards--two { grid-template-columns: 1fr; gap: .9rem; }
}

/* ---------- Page hero (non-home pages) ---------- */
.page-hero {
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #F4ECDA 0%, var(--bg) 100%);
  padding: 3.5rem 0 2.5rem;
}
.page-hero__inner { max-width: var(--measure); margin-inline: auto; padding-inline: var(--gutter); }
.breadcrumb {
  font-size: .78rem;
  letter-spacing: .08em;
  color: var(--muted);
  margin-bottom: 1rem;
  text-transform: uppercase;
}
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }
.page-hero__title {
  font-size: clamp(2rem, 3vw + 1rem, 2.75rem);
  margin: 0;
  color: var(--primary);
}
.page-hero__sub {
  margin-top: .8rem;
  color: var(--muted);
  font-size: 1.02rem;
  max-width: 36rem;
}

/* ---------- Footer ---------- */
.site-footer {
  background: #162F3D;
  color: #C8D5DC;
  padding: 3rem 0 1.4rem;
  margin-top: 4rem;
  font-size: .92rem;
}
.site-footer a { color: #E8C9B8; text-decoration: none; }
.site-footer a:hover { color: #FFFFFF; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2.5rem;
  max-width: 70rem;
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.footer-grid h4 {
  font-family: var(--serif);
  color: #FFFFFF;
  font-size: 1.05rem;
  margin: 0 0 .8rem;
  font-weight: 500;
}
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: .45rem; font-size: .9rem; }
.footer-bottom {
  max-width: 70rem;
  margin: 2.5rem auto 0;
  padding: 1.2rem var(--gutter) 0;
  border-top: 1px solid rgba(232, 201, 184, 0.18);
  display: flex;
  justify-content: space-between;
  font-size: .78rem;
  color: #8FA5AE;
}
@media (max-width: 760px) {
  .footer-grid { grid-template-columns: 1fr; gap: 1.8rem; }
  .footer-bottom { flex-direction: column; gap: .4rem; }
}

/* ---------- Utility ---------- */
.notice {
  background: rgba(199, 112, 74, 0.08);
  border-left: 3px solid var(--accent);
  padding: 1rem 1.25rem;
  margin: 2rem 0;
  font-size: .95rem;
}
.muted { color: var(--muted); }
.small { font-size: .85rem; }

/* Hide WP admin bar artifacts for non-logged-in */
.no-admin-bar #wpadminbar { display: none !important; }
html { margin-top: 0 !important; }

/* WP block defaults we keep tidy */
.wp-block-image figcaption { color: var(--muted); font-size: .85rem; margin-top: .4em; }
