/* Tokens mirror web/src/theme.css in the riil Estate repo. Keep the values in step with it. */
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('/fonts/dm-sans-core-7de4658d.woff2') format('woff2');
  unicode-range: U+0020-007E, U+00A0, U+00A3, U+00A9, U+00AE, U+00B0, U+00B7, U+00D7, U+2013-2014, U+2018-2019, U+201C-201D, U+2022, U+2026, U+20AC, U+2122, U+2191, U+2193, U+2212;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('/fonts/dm-sans-extended-45f62e34.woff2') format('woff2');
  unicode-range: U+00A1-00A2, U+00A4-00A8, U+00AA-00AD, U+00AF, U+00B1-00B6, U+00B8-00D6, U+00D8-00FF, U+0102, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+0300-0301, U+0303-0304, U+0308, U+201A, U+201E, U+2039-203A, U+2044, U+2215;
}
@font-face {
  font-family: 'Chopin';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/chopin-riil-661ddd21.woff2') format('woff2');
  unicode-range: U+0069, U+006C, U+0072;
}

:root {
  color-scheme: light dark;

  --paper: #fdf6ee;
  --surface: #ffffff;
  --ink: #1a1612;
  --soft: #5c504a;
  --muted: #7d6f68;
  --accent: #f0722a;
  --accent-ink: #9a3f11;
  --line: rgba(26, 22, 18, 0.12);
  --line-strong: rgba(26, 22, 18, 0.85);
  --status-green: #1f7a52;
  --tint: #fbe4d2;
  --panel: #1a1612;
  --panel-ink: #fdf6ee;
  --panel-soft: #cdbdb1;


  --font-sans: 'DM Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --radius-sm: 10px;
  --ease: cubic-bezier(0.23, 1, 0.32, 1);

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;
  --gutter: clamp(20px, 5vw, 56px);
  --measure: 1120px;
}

/* Dark values appear twice: once for the system setting, once for the toggle. Keep the two lists identical. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --paper: #211710;
    --surface: #261d17;
    --ink: #f3ece5;
    --soft: #cdbdb1;
    --muted: #a8998f;
    --accent: #ff8845;
    --accent-ink: #ffd2b7;
    --line: rgba(255, 236, 218, 0.14);
    --line-strong: rgba(243, 236, 229, 0.8);
    --status-green: #58d79b;
    --tint: #33261c;
    --panel: #2f241c;
  }
}

:root[data-theme='dark'] {
  color-scheme: dark;
  --paper: #211710;
  --surface: #261d17;
  --ink: #f3ece5;
  --soft: #cdbdb1;
  --muted: #a8998f;
  --accent: #ff8845;
  --accent-ink: #ffd2b7;
  --line: rgba(255, 236, 218, 0.14);
  --line-strong: rgba(243, 236, 229, 0.8);
  --status-green: #58d79b;
  --tint: #33261c;
  --panel: #2f241c;
}

:root[data-theme='light'] {
  color-scheme: light;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: var(--space-5);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
}

main {
  flex: 1;
}

h1,
h2,
h3,
p,
dl,
dd,
ul,
address {
  margin: 0;
}

h1,
h2,
h3 {
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

ul {
  padding: 0;
  list-style: none;
}

address {
  font-style: normal;
}

svg {
  flex-shrink: 0;
}

a {
  color: inherit;
  text-decoration: none;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

a:focus-visible {
  outline: 2px solid var(--accent-ink);
  outline-offset: 4px;
  border-radius: 4px;
}

::selection {
  background: var(--accent);
  color: #1a1612;
}

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: var(--space-4);
  z-index: 10;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: var(--paper);
  font-size: 14px;
  font-weight: 600;
  transform: translateY(-200%);
}

.skip-link:focus-visible {
  transform: none;
}

.container {
  width: min(var(--measure), 100% - 2 * var(--gutter));
  margin-inline: auto;
}

/* Wordmarks. The company mark follows the riil pattern: a heavy name and a regular qualifier. */

.wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: 0.26em;
  min-height: 44px;
  font-size: 20px;
  letter-spacing: -0.035em;
  line-height: 44px;
  white-space: nowrap;
}

.wordmark-name {
  font-weight: 750;
}

.wordmark-qualifier {
  font-weight: 400;
  letter-spacing: -0.02em;
}

.riil-wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: 0.28em;
  line-height: 1;
  white-space: nowrap;
}

.riil-wordmark-name,
.riil {
  font-family: 'Chopin', var(--font-sans);
  font-weight: 700;
  letter-spacing: normal;
}

.riil-wordmark-subproduct {
  font-weight: 400;
}

/* Header */

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
  min-height: 80px;
  border-bottom: 1px solid var(--line);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 3vw, 36px);
  color: var(--soft);
  font-size: 14px;
  font-weight: 500;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  transition: color 160ms var(--ease);
}

.site-nav a[aria-current='page'] {
  color: var(--ink);
}

.site-header .site-nav {
  margin-left: auto;
}

.theme-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-right: -10px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: var(--soft);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition:
    color 160ms var(--ease),
    transform 160ms var(--ease);
}

.theme-toggle[hidden] {
  display: none;
}

.theme-toggle:active {
  transform: scale(0.92);
}

.theme-toggle:focus-visible {
  outline: 2px solid var(--accent-ink);
  outline-offset: 0;
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
}

/* Show the icon for the theme a press switches to. */
.icon-sun {
  display: none;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .icon-sun {
    display: block;
  }

  :root:not([data-theme='light']) .icon-moon {
    display: none;
  }
}

:root[data-theme='dark'] .icon-sun {
  display: block;
}

:root[data-theme='dark'] .icon-moon {
  display: none;
}

/* Theme wipe: theme.js clips the incoming page; the outgoing page holds still underneath. */
:root[data-theme-wipe]::view-transition-old(root),
:root[data-theme-wipe]::view-transition-new(root) {
  animation: none;
  mix-blend-mode: normal;
}

:root[data-theme-wipe]::view-transition-new(root) {
  z-index: 1;
}

/* Links */

.text-link {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 4px;
  transition: color 160ms var(--ease);
}

.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 44px;
  font-size: 17px;
  font-weight: 600;
  white-space: nowrap;
}

.arrow-link svg {
  width: 16px;
  height: 16px;
  color: var(--accent);
  transition: transform 200ms var(--ease);
}

/* Hero */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  align-items: center;
  gap: clamp(32px, 6vw, 88px);
  padding-block: clamp(48px, 8vw, 112px);
}

.hero h1 {
  font-size: clamp(34px, 4.5vw, 58px);
  line-height: 1.06;
  letter-spacing: -0.05em;
  font-weight: 650;
}

.hero-description {
  max-width: 600px;
  margin-top: var(--space-6);
  color: var(--soft);
  font-size: clamp(17px, 1.6vw, 20px);
  line-height: 1.6;
  letter-spacing: -0.01em;
}

.hero-origin {
  margin-top: var(--space-4);
  font-size: clamp(17px, 1.6vw, 20px);
  font-weight: 650;
  letter-spacing: -0.02em;
}

.hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-6);
  margin-top: var(--space-6);
}

/* The hero artwork: a mosaic of map tiles. Its colours are fixed so it reads the same in both themes. */

.mosaic {
  display: block;
  width: 100%;
  height: auto;
}

.product-logo {
  display: block;
  width: auto;
  height: 52px;
  justify-self: center;
}

.product-logo-wide {
  width: 52px;
  height: auto;
  margin-top: 4px;
}

.logo-ink {
  fill: var(--ink);
}

.logo-accent {
  fill: var(--accent);
}

/* Rounds the corners of the straight-edged PropertyMarket.sg shapes to match the riil mark. */
.logo-round {
  stroke-width: 16;
  stroke-linejoin: round;
}

.logo-ink.logo-round {
  stroke: var(--ink);
}

.logo-accent.logo-round {
  stroke: var(--accent);
}

/* Sections: a label column and a content column under a rule. */

.section {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 9fr);
  gap: var(--space-5) var(--space-6);
  padding-block: clamp(40px, 5vw, 64px) clamp(48px, 7vw, 96px);
  border-top: 1px solid var(--line-strong);
}

.section-label {
  font-size: clamp(20px, 2vw, 24px);
  font-weight: 650;
  line-height: 1.25;
  letter-spacing: -0.03em;
}

.section-lead {
  max-width: 760px;
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1.25;
  letter-spacing: -0.035em;
  font-weight: 500;
  text-wrap: balance;
}

.section-lead + * {
  margin-top: var(--space-7);
}

/* What we do */

.areas {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6);
}

.areas li {
  padding-top: var(--space-4);
  border-top: 1px solid var(--line);
}

.icon-heading {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.line-icon {
  width: 24px;
  height: 24px;
  margin-top: 2px;
}

.areas-wide {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-6) var(--space-7);
}

.team-note {
  max-width: 600px;
  margin-top: var(--space-6);
  color: var(--soft);
  font-size: 17px;
}

.areas h3 {
  font-size: 20px;
  font-weight: 650;
  letter-spacing: -0.015em;
  line-height: 1.4;
}

.areas p {
  margin-top: var(--space-2);
  color: var(--soft);
  font-size: 17px;
}

/* Products */

.products > li {
  position: relative;
  display: grid;
  grid-template-columns: 56px minmax(228px, 4fr) minmax(0, 8fr);
  align-items: start;
  gap: var(--space-4) var(--space-6);
  padding-block: var(--space-5);
  border-top: 1px solid var(--line);
}

.products > li:last-child {
  border-bottom: 1px solid var(--line);
}

.product-name {
  font-size: 24px;
  font-weight: 650;
  letter-spacing: -0.035em;
  line-height: 1.25;
}

.product-name .riil-wordmark {
  letter-spacing: normal;
}

.product-name .riil-wordmark-subproduct {
  letter-spacing: -0.03em;
}

.status {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-2);
  color: var(--muted);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
}

.status::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.status-live::before {
  background: var(--status-green);
}

.products p {
  color: var(--soft);
  font-size: 17px;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 8px 18px 8px 14px;
  border: 1px solid var(--ink);
  border-radius: 12px;
  background: var(--ink);
  color: var(--paper);
  transition: transform 160ms var(--ease);
}

.badge:active {
  transform: scale(0.98);
}

.badge svg {
  width: 26px;
  height: 26px;
}

.badge span {
  display: grid;
  gap: 3px;
}

.badge small {
  font-size: 11px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.01em;
}

.badge strong {
  font-size: 18px;
  font-weight: 650;
  line-height: 1;
  letter-spacing: -0.02em;
}

.badge-pending {
  border-color: var(--line);
  background: transparent;
  color: var(--soft);
}

.products .product-support {
  margin-top: var(--space-4);
  font-size: 15px;
}

.role-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.role-meta li {
  padding: 5px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
}

/* Contact */

.contact {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 9fr);
  gap: var(--space-5) var(--space-6);
  margin-bottom: clamp(48px, 7vw, 96px);
  padding: clamp(28px, 5vw, 56px);
  border-radius: 20px;
  background: var(--panel);
  color: var(--panel-ink);
}

.contact .contact-note {
  color: var(--panel-soft);
}

.contact .text-link {
  color: var(--panel-ink);
}

.contact-address {
  display: inline-block;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.18em;
  font-size: clamp(22px, 3.4vw, 40px);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.contact-note {
  max-width: 520px;
  margin-top: var(--space-5);
  color: var(--soft);
  font-size: 17px;
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.footer-main {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-6) var(--space-7);
  padding-block: var(--space-7) var(--space-6);
}

.footer-company {
  max-width: 420px;
}

.footer-contact {
  margin-top: var(--space-2);
  font-size: 14px;
}

.footer-contact a {
  padding-block: 5px;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 4px;
  transition: color 160ms var(--ease);
}

.footer-copyright {
  padding-block: var(--space-4) var(--space-5);
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.footer-legal {
  margin-top: var(--space-3);
  color: var(--soft);
  font-size: 14px;
  line-height: 1.7;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, auto));
  gap: var(--space-6) clamp(32px, 6vw, 80px);
}

.footer-links h2 {
  margin-bottom: var(--space-2);
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
}

.footer-links a {
  display: inline-block;
  padding-block: 5px;
  font-size: 14px;
  transition: color 160ms var(--ease);
}

/* Careers */

.page-head {
  padding-block: clamp(48px, 8vw, 104px) clamp(40px, 6vw, 72px);
}

.page-head h1 {
  font-size: clamp(38px, 5.4vw, 68px);
  line-height: 1.06;
  letter-spacing: -0.05em;
  font-weight: 650;
}

.role {
  margin-bottom: clamp(48px, 7vw, 96px);
}

.role-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-5);
  padding: clamp(24px, 4vw, 44px);
  border-radius: 20px 20px 0 0;
  background: var(--tint);
}

.role-kicker {
  color: var(--soft);
  font-size: 15px;
  font-weight: 500;
}

.role-head h2 {
  margin-top: var(--space-1);
  font-size: clamp(28px, 3.6vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.045em;
  font-weight: 650;
}

.role-meta {
  margin-top: var(--space-4);
}

.apply {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 48px;
  padding: 12px 22px;
  border-radius: 12px;
  background: var(--ink);
  color: var(--paper);
  font-size: 16px;
  font-weight: 600;
  white-space: nowrap;
  transition: transform 160ms var(--ease);
}

.apply:active {
  transform: scale(0.98);
}

.apply svg {
  width: 16px;
  height: 16px;
  transition: transform 200ms var(--ease);
}

.role .section {
  border-top-color: var(--line);
}

.role .section:first-of-type {
  border-top: 0;
}

.copy {
  max-width: 720px;
  color: var(--soft);
  font-size: 17px;
}

.copy > * + * {
  margin-top: var(--space-4);
}

.copy .apply {
  margin-top: var(--space-5);
}

.bullets {
  padding-left: 1.2em;
  list-style: disc;
}

.bullets li + li {
  margin-top: var(--space-2);
}

.bullets li::marker {
  color: var(--accent);
}

/* Legal and error pages */

.page {
  padding-block: clamp(40px, 7vw, 88px) clamp(64px, 9vw, 112px);
}

.prose {
  max-width: 680px;
}

.prose h1 {
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.045em;
  font-weight: 650;
}

.prose .updated {
  margin-top: var(--space-4);
  color: var(--muted);
  font-size: 14px;
}

.prose h2 {
  margin-top: var(--space-7);
  font-size: 20px;
  line-height: 1.3;
  letter-spacing: -0.025em;
  font-weight: 650;
}

.prose p,
.prose ul {
  margin-top: var(--space-4);
  color: var(--soft);
}

.prose ul {
  padding-left: 1.25em;
  list-style: disc;
}

.prose li + li {
  margin-top: var(--space-2);
}

.prose li::marker {
  color: var(--muted);
}

.prose strong {
  color: var(--ink);
  font-weight: 650;
}

.not-found {
  padding-block: clamp(64px, 12vw, 160px);
}

.not-found h1 {
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.045em;
  font-weight: 650;
}

.not-found p {
  max-width: 420px;
  margin-block: var(--space-4) var(--space-5);
  color: var(--soft);
}

/* Pointer-only states, so touch devices never get a stuck hover. */

@media (hover: hover) and (pointer: fine) {
  .site-nav a:hover,
  .theme-toggle:hover,
  .footer-links a:hover,
  .footer-contact a:hover,
  .text-link:hover {
    color: var(--accent-ink);
  }

  .arrow-link:hover svg,
  .apply:hover svg {
    transform: translateX(3px);
  }

  .badge:not(.badge-pending):hover {
    transform: translateY(-1px);
  }

  .contact .text-link:hover,
  .contact-address:hover {
    color: #ffd2b7;
  }
}

@media (max-width: 860px) {
  .hero,
  .section,
  .contact {
    grid-template-columns: 1fr;
  }

  .hero-art {
    max-width: 420px;
  }

  .contact .section-label {
    color: var(--panel-soft);
  }

  .section-label {
    color: var(--muted);
  }

  .areas,
  .areas-wide {
    grid-template-columns: 1fr;
    gap: var(--space-5);
  }

  .products > li {
    grid-template-columns: 1fr;
    gap: var(--space-3);
  }

  .product-logo {
    justify-self: start;
  }


}

@media (max-width: 520px) {
  .site-header {
    min-height: 68px;
  }

  .site-nav {
    gap: 16px;
  }

  .site-nav a[data-optional] {
    display: none;
  }

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

}

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

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
