:root {
  --navy: #25241f;
  --ink: #25241f;
  --gold: #aa8050;
  --gold-soft: #efe2cf;
  --cream: #f5efe4;
  --beige: #e8ddcc;
  --white: #fffdf9;
  --muted: #716c63;
  --line: #ddd1bf;
  --shadow: 0 18px 55px -42px rgba(44, 38, 30, .55);
  --shadow-lg: 0 28px 70px -42px rgba(44, 38, 30, .62);
}

body {
  background: var(--cream);
  color: var(--ink);
  overflow-x: clip;
}

.wrap { max-width: 1080px; }

header, #hdr {
  background: rgba(247, 240, 229, .94) !important;
  border-bottom: 1px solid rgba(170, 128, 80, .12) !important;
}

header.stuck, #hdr.stuck { background: rgba(247, 240, 229, .98) !important; }
.nav { height: 70px; }
.logo::before, .logo::after { display: none; }
.logo-img { width: 112px; height: auto; }
.rk-brand .logo-img { filter: none !important; }
.rk-brand { gap: 11px; padding: 0; }
.rk-brand > span {
  border-inline-start: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.2;
  padding-inline-start: 11px;
  white-space: nowrap;
}

.rk-nav { gap: 24px; }
.rk-nav a, #hdr .rk-nav a { color: var(--muted); font-size: 13.5px; }
.rk-nav a:hover, .rk-nav a:focus-visible, #hdr .rk-nav a:hover, #hdr .rk-nav a:focus-visible { color: var(--ink); }
.rk-hdr-cta {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  min-height: 42px;
  padding: 0 16px;
}
.rk-hdr-cta:hover, .rk-hdr-cta:focus-visible { border-color: var(--gold); background: var(--white); }
.rk-hdr-cta svg { stroke: var(--gold); }
#hdr .burger span { background: var(--ink); }

.rk-home-intro { padding: 84px 0 70px; }
.rk-intro-grid {
  align-items: center;
  display: grid;
  gap: clamp(42px, 8vw, 96px);
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, .8fr);
}
.rk-intro-copy { max-width: 650px; }
.rk-kicker {
  color: var(--gold);
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .035em;
  margin-bottom: 18px;
}
.rk-kicker::before, .rk-kicker::after { display: none; }
.rk-intro-copy h1 {
  font-family: 'El Messiri', 'IBM Plex Sans Arabic', sans-serif;
  font-size: clamp(38px, 5.2vw, 64px);
  font-weight: 700;
  letter-spacing: -.025em;
  line-height: 1.28;
  max-width: 12ch;
}
.rk-intro-copy p {
  color: var(--muted);
  font-size: clamp(16px, 2vw, 19px);
  margin: 18px 0 0;
  max-width: 38ch;
}

.rk-quick-entry {
  background: rgba(255, 253, 249, .82);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 24px;
}
.rk-quick-entry > label {
  color: var(--ink);
  font-family: 'El Messiri', 'IBM Plex Sans Arabic', sans-serif;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
}
.rk-room-form {
  align-items: stretch;
  display: flex;
  direction: ltr;
  gap: 8px;
}
.rk-room-form input {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  flex: 1;
  font-family: 'IBM Plex Sans Arabic', sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .16em;
  margin: 0;
  min-width: 0;
  padding: 11px 14px;
  text-align: center;
  text-transform: uppercase;
}
.rk-room-form input::placeholder { color: #aaa296; font-size: 13px; font-weight: 500; letter-spacing: 0; }
.rk-room-actions { display: flex; gap: 7px; }
.rk-go, .rk-scan {
  align-items: center;
  border-radius: 12px;
  cursor: pointer;
  display: inline-flex;
  height: 50px;
  justify-content: center;
  width: 50px;
}
.rk-go { background: var(--ink); border: 1px solid var(--ink); color: var(--cream); }
.rk-scan { background: transparent; border: 1px solid var(--line); color: var(--muted); }
.rk-go:hover, .rk-go:focus-visible { background: #0f0f0d; }
.rk-scan:hover, .rk-scan:focus-visible { border-color: var(--gold); color: var(--gold); }
.rk-go svg, .rk-scan svg { fill: none; height: 20px; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; width: 20px; }
.rk-go:disabled { cursor: wait; opacity: .62; }
.rk-join-hint { color: var(--muted); font-size: 12.5px; margin: 10px 0 0; }
.rk-join-msg { min-height: 0; }
.rk-join-msg .alert { background: transparent; border-radius: 0; margin: 9px 0 0; padding: 0; }
.rk-join-msg .alert.info { color: var(--muted); }
.rk-join-msg .alert.ok { color: #39684f; }
.rk-join-msg .alert.err { color: #994d42; }

#games { border-top: 1px solid var(--line); padding: 54px 0 64px; }
.rk-games-head { align-items: end; margin-bottom: 24px; }
.rk-games-head .eyebrow { margin-bottom: 7px; }
.rk-games-head .eyebrow::before, .rk-games-head .eyebrow::after { display: none; }
.rk-games-head h2 { font-family: 'El Messiri', sans-serif; font-size: clamp(28px, 3.6vw, 39px); }
.rk-all { color: var(--muted); font-size: 13px; }
.rk-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.rk-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: none;
  color: var(--ink);
  display: grid;
  grid-template-areas: "identity body" "identity foot";
  grid-template-columns: minmax(155px, .82fr) minmax(0, 1.18fr);
  grid-template-rows: 1fr auto;
  min-height: 260px;
  overflow: hidden;
  position: relative;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.rk-card::after { display: none; }
.rk-card:hover { border-color: color-mix(in srgb, var(--c) 52%, var(--line)); box-shadow: var(--shadow); transform: translateY(-3px); }
.rk-card:focus-within { outline: 3px solid color-mix(in srgb, var(--gold) 30%, transparent); outline-offset: 2px; }
.rk-card-identity {
  align-items: center;
  background: var(--c);
  display: flex;
  grid-area: identity;
  justify-content: center;
  min-height: 260px;
  padding: 26px;
}
.rk-card-identity.has-brand { background: #f1e9dc; }
.rk-card-identity img { max-height: 100px; max-width: 90%; object-fit: contain; width: auto; }
.rk-card-wordmark {
  color: #fff;
  font-family: 'El Messiri', sans-serif;
  font-size: 25px;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
}
.rk-card-body { align-self: end; display: block; grid-area: body; padding: 28px 24px 10px; }
.rk-card-body > b { display: block; font-family: 'El Messiri', sans-serif; font-size: 21px; }
.rk-card-body p { color: var(--muted); font-size: 13px; margin: 4px 0 0; }
.rk-card-foot { align-self: start; background: transparent; color: var(--muted); display: block; grid-area: foot; padding: 10px 24px 24px; }
.rk-card-meta { display: flex; gap: 12px; margin-bottom: 18px; }
.rk-card-meta > span { color: var(--muted); font-size: 11.5px; }
.rk-card-meta svg { stroke: var(--gold); }
.rk-card-action {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-size: 12.5px;
  font-weight: 700;
  min-height: 42px;
  padding: 8px 14px;
  width: 100%;
}
.rk-card-action:hover, .rk-card-action:focus-visible { border-color: var(--c); }
.rk-card-own, .rk-card-tag { border-radius: 999px; font-size: 10.5px; inset-inline: auto 12px; top: 12px; z-index: 2; }
.rk-card-tag { inset-inline: 12px auto; }

#lib { border-top: 1px solid var(--line); padding: 52px 0; }
#lib .lede { margin-bottom: 24px; }

footer { background: transparent; border-radius: 0; border-top: 1px solid var(--line); color: var(--muted); margin: 0; padding: 22px 0; }
footer .bottom { border: 0; color: var(--muted); padding: 0; }

@media (prefers-reduced-motion: no-preference) {
  .rk-intro-copy, .rk-quick-entry { animation: rkExperienceIn .55s cubic-bezier(.2,.75,.25,1) both; }
  .rk-quick-entry { animation-delay: .08s; }
  @keyframes rkExperienceIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
}

@media (max-width: 820px) {
  .rk-intro-grid { gap: 32px; grid-template-columns: 1fr; }
  .rk-intro-copy { text-align: center; margin: 0 auto; }
  .rk-intro-copy h1 { margin: 0 auto; max-width: 15ch; }
  .rk-intro-copy p { margin-inline: auto; }
  .rk-quick-entry { margin: 0 auto; max-width: 480px; width: 100%; }
  .rk-grid { grid-auto-columns: min(86vw, 390px); grid-template-columns: none; }
  .rk-card { display: flex; flex-direction: column; min-height: 0; }
  .rk-card-identity { min-height: 175px; width: 100%; }
  .rk-card-body { padding: 22px 20px 8px; }
  .rk-card-foot { padding: 8px 20px 20px; }
}

@media (max-width: 640px) {
  .wrap { padding-inline: 16px; }
  .nav { height: 64px; }
  .logo-img { width: 92px; }
  .rk-brand > span { display: none; }
  .rk-hdr-cta { display: none; }
  .rk-home-intro { padding: 52px 0 44px; }
  .rk-intro-copy h1 { font-size: clamp(33px, 10vw, 44px); }
  .rk-quick-entry { border-radius: 17px; padding: 18px; }
  .rk-room-form { gap: 6px; }
  .rk-room-actions { gap: 5px; }
  .rk-go, .rk-scan { height: 48px; width: 46px; }
  #games { padding: 42px 0 50px; }
  .rk-games-head { align-items: start; flex-direction: column; gap: 4px; }
  footer .bottom { align-items: center; justify-content: center; text-align: center; }
}

/* Approved Staging identity, retaining the official account/payment/room flows. */
body, button, input, select, textarea,
.disp, .rk-intro-copy h1, .rk-games-head h2, .rk-card-body > b,
.rk-card-wordmark, .modal h3, .price, .step b {
  font-family: 'Alexandria', sans-serif !important;
}
#hdr .rk-brand .logo-img {
  width: auto !important; height: 62px !important; max-width: 140px;
  object-fit: contain; filter: none !important; background: transparent;
}
#hdr .nav { height: 88px; }
.rk-home-intro { padding: 58px 0 52px; }
.rk-intro-copy h1 { font-size: clamp(32px, 4.4vw, 54px); max-width: 17ch; }
.rk-card[data-brand="bursah"] { --c: #0B284A; border-color: #CADBE4; }
.rk-card[data-brand="mendas"] { --c: #a83c34; border-color: #3c342d; }
.rk-card[data-brand="bursah"] .rk-card-identity { background: #F0F7FA; }
.rk-card[data-brand="mendas"] .rk-card-identity { background: #211d18; }
.rk-card .rk-card-identity { padding: 14px; }
.rk-card .rk-card-body > b { color: var(--ink) !important; }
.rk-card .rk-card-identity img { max-height: 180px; max-width: 100%; border-radius: 8px; }
.rk-card[data-brand="bursah"] .rk-card-action { background: #0B284A; color: #FFFFFF; }
.rk-card[data-brand="mendas"] .rk-card-action { background: #a83c34; color: #fff9eb; }
@media(max-width:640px) {
  #hdr .nav { height: 76px; }
  #hdr .rk-brand .logo-img { height: 54px !important; }
}

/* Game four only. Existing platform/game identity is intentionally untouched. */
.rk-card[data-brand="story"] .rk-card-identity { background: #F7F0E6; }
.rk-card[data-brand="story"] .rk-card-action { background: #492c46; color: #FFFBF5; }
