/* IMOTEK — Vieira de Leiria listing. Design tokens + component styles. */
@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@400;600;800&display=swap');

:root {
  --color-bg: #f3f2f2;
  --color-text: #201e1d;
  --color-accent: #ec3013;
  --color-accent-600: #dd2b0f;
  --color-accent-700: #ae1800;
  --color-divider: color-mix(in srgb, #201e1d 40%, transparent);
  --color-neutral-200: #eae7e7;
  --color-neutral-800: #444141;
  --font-heading: "Archivo", system-ui, sans-serif;
  --font-body: "Archivo", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.55;
}

h1, h2, h3 { font-family: var(--font-heading); font-weight: 800; line-height: 1.12; letter-spacing: -0.015em; margin: 0; }

a { color: var(--color-accent-700); text-decoration: none; }
a:hover { color: var(--color-accent); text-decoration: underline; }

img { display: block; max-width: 100%; }
figure { margin: 0; }
figcaption { font-size: 12px; padding: 8px 2px 0; opacity: .75; }

/* — buttons — */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer; text-decoration: none;
  font-family: var(--font-heading); font-weight: 800;
  font-size: 14px; line-height: 1.2; color: var(--color-text);
  background: transparent; border: 1px solid transparent;
  padding: 8px 14px;
}
.btn-primary { background: var(--color-accent); color: var(--color-bg); }
.btn-primary:hover { background: var(--color-accent-600); text-decoration: none; }
.btn-secondary { border-color: var(--color-divider); }
.btn-secondary:hover { background: color-mix(in srgb, var(--color-text) 7%, transparent); text-decoration: none; }

/* — tags — */
.tag { display: inline-flex; align-items: center; font-size: 11px; letter-spacing: 0.02em; padding: 3px 10px; }
.tag-outline { border: 1px solid var(--color-accent); color: var(--color-accent); }

/* — tables — */
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th {
  text-align: left; width: 52%; font-weight: 400;
  padding: 8px; border-bottom: 2px solid var(--color-divider);
}
.table td {
  font-family: var(--font-heading); font-weight: 600;
  padding: 8px; border-bottom: 1px solid var(--color-divider);
}

/* — layout helpers — */
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.section { max-width: 1200px; margin: 0 auto; padding: 64px 24px; border-bottom: 2px solid var(--color-divider); }
.section-title {
  font-size: 13px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--color-accent); margin: 0 0 24px;
}
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; }

/* — header — */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: var(--color-bg); border-bottom: 2px solid var(--color-divider);
}
.site-header__inner {
  max-width: 1200px; margin: 0 auto; padding: 14px 24px;
  display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
}
.brand {
  margin-right: auto;
  color: inherit; text-decoration: none; display: inline-flex; align-items: center;
}
.brand-logo { display: block; }
.brand .ref {
  font-family: var(--font-body); font-weight: 400; font-size: 12px;
  letter-spacing: 0.12em; text-transform: uppercase; margin-left: 12px; opacity: .6;
}
.site-nav { display: flex; gap: 20px; font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; }
.site-nav a { color: var(--color-text); }
.site-nav a:hover { color: var(--color-accent); }
.lang-switch { display: flex; gap: 0; border: 2px solid var(--color-divider); }
.lang-switch button {
  border: 0; border-right: 1px solid var(--color-divider);
  background: transparent; color: var(--color-text);
  font-family: var(--font-heading); font-weight: 600; font-size: 12px;
  letter-spacing: 0.08em; padding: 7px 10px; cursor: pointer;
}
.lang-switch button:last-child { border-right: 0; }
.lang-switch button.is-active { background: var(--color-accent); color: #fff; }

/* — hero — */
.hero {
  max-width: 1200px; margin: 0 auto; padding: 0 24px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 0;
  border-bottom: 2px solid var(--color-divider);
}
.hero__content { padding: 56px 40px 48px 0; display: flex; flex-direction: column; justify-content: center; gap: 24px; }
.hero__kicker { font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--color-accent); }
.hero__title { font-size: clamp(34px, 4.4vw, 58px); text-wrap: balance; }
.hero__subtitle { font-size: 19px; line-height: 1.5; margin: 0; max-width: 44ch; text-wrap: pretty; }
.hero__badges { display: flex; flex-wrap: wrap; gap: 8px; }
.hero__price-row {
  display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap;
  border-top: 2px solid var(--color-divider); padding-top: 20px;
}
.hero__price { font-family: var(--font-heading); font-weight: 800; font-size: 34px; letter-spacing: -0.02em; }
.hero__price-note { font-size: 13px; opacity: .7; }
.hero__actions { display: flex; gap: 10px; flex-wrap: wrap; }
.hero__image { position: relative; min-height: 420px; border-left: 2px solid var(--color-divider); }
.hero__image img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* — descriptif — */
.paragraphs p { font-size: 16px; line-height: 1.65; margin: 0 0 16px; text-wrap: pretty; }
.intro p { font-size: 20px; line-height: 1.5; margin: 0 0 18px; text-wrap: pretty; }
.chapter-title {
  font-family: var(--font-heading); font-weight: 700; font-size: 16px;
  margin: 28px 0 4px; text-wrap: pretty;
}
.chapter-title:first-child { margin-top: 0; }
.chapter-body { font-size: 16px; line-height: 1.65; margin: 0 0 16px; text-wrap: pretty; }
.table-block + .table-block { margin-top: 40px; }
.table-block .section-title { margin: 0 0 24px; }

/* — gallery — */
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.gallery-item { position: relative; cursor: zoom-in; border: 0; background: none; padding: 0; text-align: left; display: block; width: 100%; }
.gallery-item__frame { aspect-ratio: 4 / 3; overflow: hidden; background: var(--color-neutral-200); }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; }

/* — catalogue — */
.catalogue-hero { padding-bottom: 40px; display: flex; flex-direction: column; gap: 16px; }
.catalogue-hero .hero__title { font-size: clamp(30px, 3.6vw, 46px); }
.catalogue-hero .hero__subtitle { max-width: 56ch; }
.catalogue-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px 24px; }
.catalogue-card { display: block; color: inherit; }
.catalogue-card:hover { color: inherit; text-decoration: none; }
.catalogue-card__frame { aspect-ratio: 4 / 3; overflow: hidden; background: var(--color-neutral-200); }
.catalogue-card__frame img { width: 100%; height: 100%; object-fit: cover; }
.catalogue-card:hover .catalogue-card__frame img { opacity: .9; }
.catalogue-card__body { padding: 16px 2px; }
.catalogue-card__ref { margin-bottom: 10px; }
.catalogue-card__title { font-size: 19px; margin: 0 0 6px; text-wrap: pretty; }
.catalogue-card__loc { font-size: 13px; opacity: .7; margin-bottom: 10px; }
.catalogue-card__blurb { font-size: 14px; line-height: 1.55; opacity: .85; margin: 0 0 12px; text-wrap: pretty; }
.catalogue-card__price { font-family: var(--font-heading); font-weight: 800; font-size: 18px; color: var(--color-accent); }

/* — videos — */
.video-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.video-grid video { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--color-neutral-800); display: block; }

/* — documents — */
.doc-list { display: flex; flex-direction: column; gap: 0; border-top: 2px solid var(--color-divider); }
.doc-list a {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 0; border-bottom: 1px solid var(--color-divider);
  color: var(--color-text); font-family: var(--font-heading); font-weight: 600; font-size: 15px;
}
.doc-list a:hover { color: var(--color-accent); text-decoration: none; }
.doc-list .cta { font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-accent); }

/* — localisation — */
.location-link {
  display: block; font-family: var(--font-heading); font-weight: 800; font-size: 26px;
  margin-bottom: 16px; color: var(--color-text);
}
.location-link:hover { color: var(--color-accent); text-decoration: none; }
.paragraphs a { color: inherit; }
.paragraphs a:hover { color: var(--color-accent); }
.price-row-2 {
  border-top: 2px solid var(--color-divider); margin-top: 8px; padding-top: 20px;
  display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap;
}
.price-row-2 .price { font-family: var(--font-heading); font-weight: 800; font-size: 30px; }
.price-row-2 .note { font-size: 13px; opacity: .7; }

/* — contact — */
.contact-section { background: var(--color-accent); color: #fff; }
.contact-inner { max-width: 1200px; margin: 0 auto; padding: 72px 24px; }
.contact-kicker { font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase; opacity: .8; margin-bottom: 20px; }
.contact-title { font-size: clamp(30px, 3.6vw, 48px); color: #fff; margin: 0 0 12px; max-width: 26ch; text-wrap: balance; }
.contact-sub { font-size: 17px; max-width: 48ch; margin: 0 0 32px; opacity: .9; }
.contact-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2px;
  border-top: 2px solid rgba(255,255,255,.4);
}
.contact-grid a {
  padding: 24px 0; border-bottom: 1px solid rgba(255,255,255,.35);
  color: #fff; font-family: var(--font-heading); font-weight: 800; font-size: 18px;
}
.contact-grid a:hover { opacity: .75; text-decoration: none; }
.contact-grid .sub { font-family: var(--font-body); font-weight: 400; font-size: 14px; opacity: .85; margin-top: 6px; }

/* — footer — */
.site-footer {
  max-width: 1200px; margin: 0 auto; padding: 28px 24px;
  display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; opacity: .7;
}

/* — lightbox — */
.lightbox {
  position: fixed; inset: 0; z-index: 60; background: rgba(32,30,29,.94);
  display: flex; align-items: center; justify-content: center; padding: 32px; cursor: zoom-out;
}
.lightbox[hidden] { display: none; }
.lightbox img { max-width: 100%; max-height: 82vh; object-fit: contain; cursor: default; }
.lightbox-caption { position: absolute; bottom: 24px; left: 0; right: 0; text-align: center; color: #fff; font-size: 14px; }
.lightbox-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: none; border: 2px solid rgba(255,255,255,.6); color: #fff;
  font-size: 20px; padding: 8px 14px; cursor: pointer;
}
.lightbox-btn.prev { left: 16px; }
.lightbox-btn.next { right: 16px; }

@media (max-width: 860px) {
  .grid-2 { grid-template-columns: 1fr !important; }
  .hero { grid-template-columns: 1fr !important; }
  .gallery-grid { grid-template-columns: 1fr 1fr !important; }
  .video-grid { grid-template-columns: 1fr !important; }
  .catalogue-grid { grid-template-columns: 1fr 1fr !important; }
}
