:root {
  --mr-ink: #183438;
  --mr-muted: #587175;
  --mr-deep: #0c3e46;
  --mr-sea: #0f7180;
  --mr-sea-soft: #dcecef;
  --mr-sand: #f4efe4;
  --mr-canvas: #fbfaf6;
  --mr-white: #ffffff;
  --mr-line: rgba(24, 52, 56, 0.16);
  --mr-shadow: 0 24px 64px rgba(12, 62, 70, 0.14);
  --mr-radius: 28px;
  --mr-shell: min(1180px, calc(100% - 40px));
}

html {
  scroll-behavior: smooth;
}

body.mr-page {
  background: var(--mr-canvas);
  color: var(--mr-ink);
}

.mr-page img {
  max-width: 100%;
}

.mr-shell {
  width: var(--mr-shell);
  margin-inline: auto;
}

.mr-section {
  padding: clamp(76px, 9vw, 132px) 0;
}

.mr-section--sand {
  background: var(--mr-sand);
}

.mr-section--deep {
  background: var(--mr-deep);
  color: var(--mr-white);
}

.mr-kicker {
  margin: 0 0 14px;
  color: var(--mr-sea);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}

.mr-section--deep .mr-kicker {
  color: #89cbd2;
}

.mr-page h1,
.mr-page h2,
.mr-page h3 {
  color: inherit;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: -0.035em;
}

.mr-page h2 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2.2rem, 5vw, 4.5rem);
  line-height: 0.98;
}

.mr-lede {
  max-width: 680px;
  margin: 24px 0 0;
  color: var(--mr-muted);
  font-size: clamp(1.04rem, 1.6vw, 1.22rem);
  line-height: 1.72;
}

.mr-section--deep .mr-lede {
  color: rgba(255, 255, 255, 0.74);
}

.mr-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 44px;
  margin-bottom: 42px;
}

.mr-heading > p {
  max-width: 410px;
  margin: 0;
  color: var(--mr-muted);
  line-height: 1.7;
}

.mr-section--deep .mr-heading > p {
  color: rgba(255, 255, 255, 0.72);
}

.mr-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(54px, 6vw, 90px) 0 clamp(72px, 8vw, 112px);
  background:
    radial-gradient(circle at 10% 15%, rgba(120, 198, 205, 0.3), transparent 35%),
    linear-gradient(135deg, #eaf4f3 0%, #f7f2e7 56%, #e6f1f1 100%);
}

.mr-hero::after {
  position: absolute;
  right: -10vw;
  bottom: -34vw;
  width: 72vw;
  height: 72vw;
  border: 1px solid rgba(15, 113, 128, 0.16);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.mr-hero__grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr);
  align-items: center;
  gap: clamp(38px, 6vw, 88px);
}

.mr-hero h1 {
  max-width: 640px;
  margin: 0;
  font-size: clamp(3.2rem, 7.6vw, 7.2rem);
  line-height: 0.87;
}

.mr-hero__lede {
  max-width: 580px;
  margin: 28px 0 0;
  color: #426267;
  font-size: clamp(1.05rem, 1.65vw, 1.28rem);
  line-height: 1.7;
}

.mr-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.mr-button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 13px 20px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
  transition: transform 180ms ease, background 180ms ease, color 180ms ease, border-color 180ms ease;
}

.mr-button:hover {
  transform: translateY(-2px);
}

.mr-button:focus-visible,
.mr-tab:focus-visible,
.mr-media:focus-visible,
.mr-lightbox__close:focus-visible {
  outline: 3px solid #f5b95f;
  outline-offset: 3px;
}

.mr-button--primary {
  background: var(--mr-sea);
  color: var(--mr-white);
}

.mr-button--primary:hover {
  background: #0a5e6a;
  color: var(--mr-white);
}

.mr-button--ghost {
  border-color: rgba(12, 62, 70, 0.34);
  background: rgba(255, 255, 255, 0.54);
  color: var(--mr-deep);
}

.mr-button--light {
  background: var(--mr-white);
  color: var(--mr-deep);
}

.mr-hero__visual {
  position: relative;
  margin: 0;
}

.mr-hero__frame {
  position: relative;
  overflow: hidden;
  border: 9px solid rgba(255, 255, 255, 0.78);
  border-radius: 44px 44px 44px 120px;
  box-shadow: var(--mr-shadow);
}

.mr-hero__frame img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  background: #d5e6e5;
}

.mr-hero__visual figcaption {
  margin: 12px 12px 0;
  color: #5f7476;
  font-size: 0.8rem;
}

.mr-hero__badge {
  position: absolute;
  right: -18px;
  bottom: 32px;
  max-width: 190px;
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(12, 62, 70, 0.94);
  color: #fff;
  box-shadow: 0 18px 42px rgba(12, 62, 70, 0.24);
  font-size: 0.85rem;
  line-height: 1.45;
}

.mr-proof {
  position: relative;
  z-index: 2;
  margin-top: -34px;
}

.mr-proof__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  overflow: hidden;
  border: 1px solid var(--mr-line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 14px 40px rgba(24, 52, 56, 0.1);
}

.mr-proof__grid div {
  padding: 24px clamp(18px, 2.5vw, 32px);
}

.mr-proof__grid div + div {
  border-left: 1px solid var(--mr-line);
}

.mr-proof dt {
  color: var(--mr-muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.mr-proof dd {
  margin: 6px 0 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.18rem, 2vw, 1.6rem);
}

.mr-journey {
  position: sticky;
  z-index: 20;
  top: 74px;
  border-bottom: 1px solid var(--mr-line);
  background: rgba(251, 250, 246, 0.94);
  backdrop-filter: blur(14px);
}

.mr-journey__inner {
  display: flex;
  gap: 26px;
  overflow-x: auto;
  padding-block: 14px;
  scrollbar-width: none;
}

.mr-journey__inner::-webkit-scrollbar {
  display: none;
}

.mr-journey a {
  display: inline-flex;
  flex: 0 0 auto;
  min-height: 44px;
  align-items: center;
  color: var(--mr-muted);
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}

.mr-intro {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  align-items: center;
  gap: clamp(42px, 7vw, 96px);
}

.mr-intro__image {
  margin: 0;
  overflow: hidden;
  border-radius: var(--mr-radius);
  box-shadow: var(--mr-shadow);
}

.mr-intro__image img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  background: #d9e9e8;
}

.mr-intro__copy p:not(.mr-kicker) {
  color: var(--mr-muted);
  font-size: 1.08rem;
  line-height: 1.75;
}

.mr-signals {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 48px;
}

.mr-signal {
  padding: 28px;
  border: 1px solid var(--mr-line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.72);
}

.mr-signal span {
  display: block;
  color: var(--mr-sea);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
}

.mr-signal h3 {
  margin: 18px 0 10px;
  font-size: 1.45rem;
}

.mr-signal p {
  margin: 0;
  color: var(--mr-muted);
  line-height: 1.65;
}

.mr-location {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: 36px;
  align-items: stretch;
}

.mr-location__copy {
  padding: clamp(30px, 5vw, 62px);
  border-radius: var(--mr-radius);
  background: var(--mr-deep);
  color: var(--mr-white);
}

.mr-location__copy p:not(.mr-kicker) {
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.72;
}

.mr-location__list {
  display: grid;
  gap: 15px;
  margin: 30px 0;
  padding: 0;
  list-style: none;
}

.mr-location__list li {
  padding-left: 24px;
  background: linear-gradient(#85cad1, #85cad1) 0 0.72em / 9px 2px no-repeat;
  line-height: 1.55;
}

.mr-map {
  min-height: 540px;
  overflow: hidden;
  border: 1px solid var(--mr-line);
  border-radius: var(--mr-radius);
  background: var(--mr-sea-soft);
}

.mr-map iframe {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 540px;
  border: 0;
}

.mr-plan-stage {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 24px;
}

.mr-plan-card {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--mr-line);
  border-radius: var(--mr-radius);
  background: #fff;
}

.mr-media {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: zoom-in;
  text-align: left;
}

.mr-plan-card img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  background: #f4f0e8;
}

.mr-plan-card figcaption {
  padding: 18px 20px 20px;
  color: var(--mr-muted);
  line-height: 1.55;
}

.mr-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  margin-bottom: 22px;
  padding: 4px 2px 8px;
  scrollbar-width: thin;
}

.mr-tab {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 10px 17px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  background: transparent;
  color: #fff;
  cursor: pointer;
  font-weight: 800;
}

.mr-tab[aria-selected="true"] {
  border-color: var(--mr-white);
  background: var(--mr-white);
  color: var(--mr-deep);
}

.mr-layout-panel[hidden] {
  display: none;
}

.mr-layout-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 26px;
  align-items: stretch;
}

.mr-layout-panel__plans {
  display: grid;
  gap: 16px;
}

.mr-layout-panel__plans--two {
  grid-template-columns: repeat(2, 1fr);
}

.mr-layout-panel figure {
  margin: 0;
  overflow: hidden;
  border-radius: 22px;
  background: #fff;
}

.mr-layout-panel figure img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  background: #f4f0e8;
}

.mr-layout-panel figure figcaption {
  padding: 12px 16px 15px;
  color: #496267;
  font-size: 0.88rem;
}

.mr-layout-panel__copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.07);
}

.mr-layout-panel__copy h3 {
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 4rem);
}

.mr-layout-panel__copy p {
  color: rgba(255, 255, 255, 0.74);
  line-height: 1.68;
}

.mr-layout-facts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 22px 0 26px;
}

.mr-layout-facts div {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
}

.mr-layout-facts dt {
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.72rem;
  text-transform: uppercase;
}

.mr-layout-facts dd {
  margin: 4px 0 0;
  font-weight: 800;
}

.mr-gallery {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 14px;
}

.mr-gallery figure {
  grid-column: span 4;
  margin: 0;
  overflow: hidden;
  border-radius: 20px;
  background: #dce9e8;
}

.mr-gallery figure:nth-child(7n + 1),
.mr-gallery figure:nth-child(7n + 5) {
  grid-column: span 8;
}

.mr-gallery img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  transition: transform 300ms ease;
}

.mr-gallery .mr-media:hover img {
  transform: scale(1.02);
}

.mr-gallery figcaption {
  padding: 11px 14px 14px;
  color: var(--mr-muted);
  font-size: 0.84rem;
}

.mr-player,
.mr-tour {
  overflow: hidden;
  border-radius: var(--mr-radius);
  background: #052f35;
  box-shadow: var(--mr-shadow);
}

.mr-player {
  aspect-ratio: 16 / 9;
}

.mr-player iframe,
.mr-tour iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.mr-tour {
  height: min(72vh, 690px);
  min-height: 500px;
}

.mr-media-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.mr-cta {
  position: relative;
  overflow: hidden;
  border-radius: 36px;
  background:
    linear-gradient(90deg, rgba(7, 49, 56, 0.95), rgba(7, 49, 56, 0.68)),
    url("images/marina-residence/optimized/clubhouse-sea.webp") center / cover no-repeat;
  color: #fff;
}

.mr-cta__inner {
  max-width: 760px;
  padding: clamp(48px, 8vw, 96px);
}

.mr-cta h2 {
  font-size: clamp(2.6rem, 6vw, 5.4rem);
}

.mr-cta p {
  max-width: 620px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.08rem;
  line-height: 1.7;
}

.mr-source-note {
  padding: 24px 0;
  border-top: 1px solid var(--mr-line);
  color: var(--mr-muted);
  font-size: 0.82rem;
  line-height: 1.65;
}

.mr-source-note a {
  color: var(--mr-sea);
}

.mr-lightbox {
  position: fixed;
  z-index: 1000;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(4, 25, 29, 0.92);
}

.mr-lightbox[hidden] {
  display: none;
}

.mr-lightbox__content {
  position: relative;
  width: min(1200px, 96vw);
  max-height: 92vh;
}

.mr-lightbox__content img {
  display: block;
  width: 100%;
  max-height: 82vh;
  object-fit: contain;
  border-radius: 18px;
  background: #f6f2e8;
}

.mr-lightbox__caption {
  margin: 12px 54px 0 4px;
  color: rgba(255, 255, 255, 0.82);
}

.mr-lightbox__close {
  position: absolute;
  top: -18px;
  right: -14px;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  background: #fff;
  color: var(--mr-deep);
  cursor: pointer;
  font-size: 1.5rem;
}

.mr-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 600ms ease, transform 600ms ease;
}

.mr-reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (max-width: 980px) {
  .mr-hero__grid,
  .mr-intro,
  .mr-location,
  .mr-layout-panel {
    grid-template-columns: 1fr;
  }

  .mr-hero__copy {
    max-width: 760px;
  }

  .mr-hero h1 {
    max-width: 740px;
  }

  .mr-proof__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .mr-proof__grid div:nth-child(3) {
    border-left: 0;
  }

  .mr-proof__grid div:nth-child(n + 3) {
    border-top: 1px solid var(--mr-line);
  }

  .mr-plan-stage {
    grid-template-columns: 1fr;
  }

  .mr-gallery figure,
  .mr-gallery figure:nth-child(7n + 1),
  .mr-gallery figure:nth-child(7n + 5) {
    grid-column: span 6;
  }

  .mr-tour {
    min-height: 560px;
  }
}

@media (max-width: 720px) {
  :root {
    --mr-shell: min(100% - 28px, 1180px);
    --mr-radius: 22px;
  }

  .mr-section {
    padding: 72px 0;
  }

  .mr-heading {
    display: block;
  }

  .mr-heading > p {
    margin-top: 20px;
  }

  .mr-hero {
    padding-top: 38px;
  }

  .mr-hero h1 {
    font-size: clamp(3rem, 16vw, 4.8rem);
    line-height: 0.9;
  }

  .mr-hero__frame {
    border-width: 6px;
    border-radius: 28px 28px 28px 66px;
  }

  .mr-hero__badge {
    position: static;
    max-width: none;
    margin-top: 10px;
  }

  .mr-proof {
    margin-top: -24px;
  }

  .mr-proof__grid {
    grid-template-columns: 1fr;
  }

  .mr-proof__grid div + div,
  .mr-proof__grid div:nth-child(3) {
    border-top: 1px solid var(--mr-line);
    border-left: 0;
  }

  .mr-journey {
    top: 64px;
  }

  .mr-signals {
    grid-template-columns: 1fr;
  }

  .mr-map,
  .mr-map iframe {
    min-height: 420px;
  }

  .mr-layout-panel__plans--two {
    grid-template-columns: 1fr;
  }

  .mr-layout-panel__copy {
    order: -1;
  }

  .mr-gallery figure,
  .mr-gallery figure:nth-child(7n + 1),
  .mr-gallery figure:nth-child(7n + 5) {
    grid-column: 1 / -1;
  }

  .mr-gallery img {
    aspect-ratio: 16 / 10;
    object-fit: contain;
  }

  .mr-tour {
    height: 68vh;
    min-height: 460px;
  }

  .mr-cta {
    border-radius: 26px;
  }

  .mr-lightbox {
    padding: 14px;
  }

  .mr-lightbox__close {
    top: 8px;
    right: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .mr-button,
  .mr-gallery img,
  .mr-reveal {
    transition: none;
  }

  .mr-reveal {
    opacity: 1;
    transform: none;
  }
}

html.mr-reduced-motion {
  scroll-behavior: auto;
}

html.mr-reduced-motion .mr-button,
html.mr-reduced-motion .mr-gallery img,
html.mr-reduced-motion .mr-reveal {
  transition: none;
}

html.mr-reduced-motion .mr-reveal {
  opacity: 1;
  transform: none;
}
