/* The printed data sheet as a designed page — src/web/unit-print.js draws it
   from a template (src/core/sheet-template.js). Loaded by the viewer (the
   visitor's print) AND by the admin pages (the designer's preview), so the two
   are one stylesheet and cannot drift. Sizes are in mm / pt: this is a page,
   not a screen, and the designer scales the whole page to fit its canvas.
   No transitions here — nothing on paper moves. */

/* Inter, self-hosted (vendor/inter-5.3.0, vendor/README.md): the page looks
   the same in the visitor's print, the designer and the generated PDF, on any
   machine — a system font did not (the PDF's Linux browser has none of ours).
   Two subsets; latin-ext carries ő and ű. The unicode ranges are fontsource's. */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-display: block;
  font-weight: 100 900;
  src: url("../vendor/inter-5.3.0/inter-latin-ext-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-display: block;
  font-weight: 100 900;
  src: url("../vendor/inter-5.3.0/inter-latin-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

.ff-sheet-page {
  --ff-text: #111;
  --ff-muted: #5b5b5b;
  --ff-border: #d6d6d6;
  --ff-chip-bg: #f1f1f1;
  --ff-chip-text: #222;
  position: relative;
  box-sizing: border-box;
  overflow: hidden;
  background: #fff;
  color: #111;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 9.5pt;
  line-height: 1.3;
  text-align: left;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}
.ff-sheet-page *,
.ff-sheet-page *::before,
.ff-sheet-page *::after {
  box-sizing: border-box;
}

.ff-sp-block {
  position: absolute;
  /* half a gutter each side, so two blocks on neighbouring cells never touch */
  padding: 0 1.5mm;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}
.ff-sp-inner {
  min-width: 0;
}
/* Pictures and the rule sit in the middle of their block. */
.ff-sp-logo,
.ff-sp-plan,
.ff-sp-line {
  justify-content: center;
}
.ff-sp-logo .ff-sp-inner,
.ff-sp-plan .ff-sp-inner {
  display: flex;
  justify-content: center;
}
.ff-sp-block[data-align="left"] .ff-sp-inner {
  justify-content: flex-start;
}
.ff-sp-block[data-align="right"] .ff-sp-inner {
  justify-content: flex-end;
}
.ff-sp-logo img {
  display: block;
  width: auto;
  height: auto;
  object-fit: contain;
}

.ff-sp-title {
  justify-content: center;
}
.ff-sp-crumbs {
  color: var(--ff-muted);
  font-size: 1.05em;
}
.ff-sp-code {
  font-size: 1.9em;
  font-weight: 700;
  line-height: 1.15;
}
.ff-sp-kind {
  font-weight: 400;
}
.ff-sp-featured {
  display: inline-block;
  margin-left: 0.4em;
  padding: 0.1em 0.6em;
  border-radius: 99px;
  font-size: 0.42em;
  font-weight: 700;
  vertical-align: middle;
  color: #3a2600;
  background: #f5b000;
}

/* A rule in the brand colour; its weight comes from the block (`--ff-sp-rule`,
   set by unit-print.js). A line block has no thickness of its own — it lies
   on a grid line (core/sheet-template.js) — so the rule is centred ON that
   line and overflows it by half its weight each side. A horizontal one keeps
   the blocks' side gutter, so its ends line up with the text; a vertical one
   runs its full length. */
.ff-sp-line {
  overflow: visible;
}
.ff-sp-rule {
  height: 0;
  border-top: var(--ff-sp-rule, 1.7pt) solid var(--ff-brand, #2563eb);
}
.ff-sp-line--v {
  padding: 0;
  align-items: center;
}
.ff-sp-line--v .ff-sp-inner {
  height: 100%;
}
.ff-sp-line--v .ff-sp-rule {
  width: 0;
  height: 100%;
  border-top: 0;
  border-left: var(--ff-sp-rule, 1.7pt) solid var(--ff-brand, #2563eb);
}

/* A gallery fills its block: a grid of cells, each photo cropped to its cell. */
.ff-sp-gallery .ff-sp-inner {
  height: 100%;
}
.ff-sp-photos {
  display: grid;
  gap: 1.5mm;
  width: 100%;
  height: 100%;
}
.ff-sp-photos img {
  display: block;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  object-fit: cover;
  border-radius: 1mm;
}

.ff-sp-figure {
  position: relative;
  width: fit-content;
}
.ff-sp-figure img {
  display: block;
  width: auto;
  height: auto;
}
.ff-sp-pin {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 5.2mm;
  height: 5.2mm;
  margin: -2.6mm 0 0 -2.6mm;
  border: 0.3mm solid #fff;
  border-radius: 50%;
  background: var(--ff-brand, #2563eb);
  color: #fff;
  font-size: 7pt;
  font-weight: 700;
  line-height: 1;
}

/* The sheet's own tables, at paper sizes. */
.ff-sheet-page .ff-unit-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 1em;
}
.ff-sheet-page .ff-unit-table th,
.ff-sheet-page .ff-unit-table td {
  padding: 0.45em 0;
  border-bottom: 0.25mm solid var(--ff-border);
  text-align: left;
  vertical-align: baseline;
}
.ff-sheet-page .ff-unit-table th {
  font-weight: 500;
  color: var(--ff-muted);
}
.ff-sheet-page .ff-unit-table td {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.ff-sheet-page .ff-unit-table .ff-unit-row--big th,
.ff-sheet-page .ff-unit-table .ff-unit-row--big td,
.ff-sheet-page .ff-unit-rooms tfoot th,
.ff-sheet-page .ff-unit-rooms tfoot td {
  font-size: 1.08em;
  font-weight: 700;
  color: var(--ff-text);
}
.ff-sheet-page .ff-unit-rooms th {
  color: var(--ff-text);
}
/* The screen sheet sets these in px (viewer.css); on paper they must follow
   the block's font size, or a shrunk list keeps its tall rows. */
.ff-sheet-page .ff-unit-rooms td {
  line-height: inherit;
}
.ff-sheet-page .ff-unit-rooms tfoot .ff-unit-rooms-area td,
.ff-sheet-page .ff-unit-rooms tfoot .ff-unit-rooms-area th {
  padding-bottom: 0.9em;
}
.ff-sheet-page .ff-unit-room-num {
  display: inline-block;
  min-width: 1.2em;
  margin-right: 0.6em;
  color: var(--ff-muted);
  font-weight: 600;
  text-align: right;
}
.ff-sheet-page .ff-unit-features {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4em;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ff-sheet-page .ff-unit-features li {
  padding: 0.2em 0.7em;
  border-radius: 99px;
  background: var(--ff-chip-bg);
  color: var(--ff-chip-text);
}

.ff-sp-price {
  justify-content: center;
}
.ff-sp-price-value {
  font-size: 1.8em;
  font-weight: 700;
}

/* The `status` block: the availability as a badge, in the drawing key's own
   colours (spelled out here — the PDF loads this sheet alone). */
.ff-sp-badge {
  display: inline-block;
  padding: 0.25em 0.9em;
  border-radius: 99px;
  font-size: 1.1em;
  font-weight: 700;
  color: #fff;
  background: #64748b;
}

.ff-sp-badge--free {
  background: #16a34a;
}

.ff-sp-badge--reserved {
  background: #d97706;
}

.ff-sp-badge--sold {
  background: #9ca3af;
}

.ff-sp-text {
  white-space: pre-line;
}

.ff-sp-contact,
.ff-sp-note {
  justify-content: flex-end;
  font-size: 0.9em;
}
.ff-sp-note {
  color: var(--ff-muted);
}
.ff-sp-date {
  font-weight: 600;
  color: var(--ff-text);
}

/* --- where the page lives ------------------------------------------------------
   In the viewer the page is built at the press of the print button, as a
   direct child of <body> (unit-sheet.js): invisible on screen but LAID OUT
   (fitting text needs sizes), and on paper the only thing shown. Outside the
   data sheet on purpose — the sheet's dark-glass rules must not reach it. */
.ff-unit-print {
  position: fixed;
  left: -10000px;
  top: 0;
  visibility: hidden;
  pointer-events: none;
}

@media print {
  body:has(> .ff-unit-print) > :not(.ff-unit-print) {
    display: none !important;
  }
  body:has(> .ff-unit-print) {
    background: #fff !important;
    margin: 0;
  }
  .ff-unit-print {
    position: static;
    visibility: visible;
  }
}
