/* ==========================================================================
   Homepage "Our rooms" section (templates/index.html)
   Same palette as the header/footer and other redesigned pages.
   ========================================================================== */

.home-rooms {
  --rm-ink: #171b24;
  --rm-muted: #676459;
  --rm-line: #e9e4d8;
  --rm-tint: #f7f5f0;
  --rm-primary: #1f2a44;
  --rm-primary-hover: #151d31;
  --rm-primary-soft: rgba(31, 42, 68, 0.08);
  --rm-gold: #b8903f;
  --rm-shadow: 0 1px 2px rgba(23, 27, 36, 0.04), 0 22px 44px -22px rgba(23, 27, 36, 0.3);

  padding: 5.5rem 0 3rem !important;
  color: var(--rm-muted);
}

/* style.css removes the container's side padding site-wide; restore it here */
.home-rooms .container {
  padding-left: calc(var(--bs-gutter-x) * 0.5);
  padding-right: calc(var(--bs-gutter-x) * 0.5);
}

/* ---------- Heading ---------- */

.rm-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 2rem;
  margin-bottom: 2.5rem;
}

.rm-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.9rem;
  color: var(--rm-gold);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.rm-eyebrow::before {
  content: "";
  width: 1.75rem;
  height: 1px;
  background: currentColor;
}

.rm-head h2 {
  margin-bottom: 0.5rem;
  color: var(--rm-ink);
  font-size: clamp(1.9rem, 1.3rem + 2vw, 2.75rem);
  letter-spacing: 0;
}

.rm-head p {
  max-width: 34rem;
  margin: 0;
  font-size: 1.05rem;
}

.rm-all {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.75rem 1.25rem;
  border: 1px solid rgba(23, 27, 36, 0.15);
  border-radius: 999px;
  color: var(--rm-ink);
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.rm-all:hover {
  border-color: var(--rm-primary);
  color: var(--rm-primary);
}

/* ---------- Card ---------- */

.rm-card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--rm-line);
  border-radius: 1.5rem;
  background: #fff;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.rm-card:hover {
  transform: translateY(-4px);
  border-color: transparent;
  box-shadow: var(--rm-shadow);
}

.rm-media {
  position: relative;
  display: block;
  margin: 0;
  overflow: hidden;
  background: var(--rm-tint);
}

.rm-media img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.rm-card:hover .rm-media img {
  transform: scale(1.05);
}

.rm-save,
.rm-photos {
  position: absolute;
  top: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
}

.rm-save {
  left: 1rem;
  background: linear-gradient(135deg, #e2c27a, #b8903f);
  color: #1c1608;
}

.rm-photos {
  right: 1rem;
  background: rgba(10, 14, 23, 0.55);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  color: #fff;
}

.rm-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 1.35rem 1.5rem 1.5rem;
}

.rm-body h3 {
  margin-bottom: 0.75rem;
  font-size: 1.2rem;
  line-height: 1.3;
}

.rm-body h3 a {
  color: var(--rm-ink);
  text-decoration: none;
}

/* whole card clickable through the title link */
.rm-body h3 a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}

.rm-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.1rem;
  margin: 0 0 1rem;
  padding: 0;
  list-style: none;
  color: var(--rm-ink);
  font-size: 0.9rem;
}

.rm-meta i {
  margin-right: 0.35rem;
  color: var(--rm-gold);
}

.rm-amenities {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0 0 1.25rem;
  padding: 0;
  list-style: none;
}

.rm-amenities li {
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  background: var(--rm-tint);
  color: var(--rm-muted);
  font-size: 0.8rem;
  font-weight: 500;
}

.rm-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: auto;
  padding-top: 1.1rem;
  border-top: 1px solid var(--rm-line);
}

.rm-price {
  line-height: 1.1;
}

.rm-price strong {
  color: var(--rm-ink);
  font-family: var(--bs-heading-font-family, "Playfair Display", Georgia, serif);
  font-size: 1.45rem;
}

.rm-price span {
  font-size: 0.85rem;
}

.rm-price s {
  margin-left: 0.3rem;
  color: #a7a194;
  font-size: 0.88rem;
}

/* sits above the full-card link */
.home-rooms .rm-book {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.1rem;
  border-radius: 999px;
  background: var(--rm-primary);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 10px 24px -12px rgba(31, 42, 68, 0.85);
  transition: background-color 0.2s ease;
}

.home-rooms .rm-book:hover {
  background: var(--rm-primary-hover);
  color: #fff;
}

.home-rooms a:focus-visible {
  outline: 2px solid var(--rm-primary);
  outline-offset: 3px;
}

.rm-body h3 a:focus-visible {
  outline: none;
}

.rm-card:has(h3 a:focus-visible) {
  outline: 2px solid var(--rm-primary);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .home-rooms * {
    transition: none !important;
  }
}

@media (max-width: 575.98px) {
  .home-rooms {
    padding-top: 3.5rem !important;
  }

  .rm-all {
    width: 100%;
    justify-content: center;
  }
}
