/* ============================================================================
   pd2-rail.css — Decision rail & contact reveal
   OWNER: W3. No other workstream may edit this file.

   EVERY selector in this file must start with `.pd2-r-`.
   Consume the tokens from pd2-tokens.css (var(--pd2-*)); do not hardcode a
   colour, radius or shadow that already exists there.
   This file owns its own responsive rules — there is no shared responsive file.

   Design source: website html/index/property-detail-v3.html
     .rail / .card / .price-card / .pc-* / .btn-primary / .btn-ghost /
     .reveal-box / .rb-* / .g-ribbon / .owner-card / .oc-* / .safety

   SPECIFICITY NOTE — pd2-tokens.css resets buttons, links, images and
   headings as `.pd2-root button` / `.pd2-root a` (0,1,1). A bare component
   class (0,1,0) LOSES to that, so a `.pd2-r-btn{background:...}` written flat
   would render transparent. Every component rule below is therefore written
   as a descendant of `.pd2-r-rail` (0,2,0) — which still starts with the
   stream's prefix, and keeps the whole section immune to the shared reset.
   ========================================================================== */

/* ----------------------------------------------------------- rail column --
   Prototype puts `position:sticky` on `.rail`, which IS the grid item — a
   grid item sticks inside its grid AREA (full row height), not inside its own
   auto height, which is what makes it work under `align-items:start`.
   The shell renders the grid item as <aside class="pd2-rail-col"> (W0's file,
   W0's prefix), so the partial tags that same element with `.pd2-r-col` at
   parse time and the sticky lives here, inside this stream's prefix. */
.pd2-r-col{position:sticky;top:78px}
.pd2-r-rail{display:flex;flex-direction:column;gap:14px}

/* ---------------------------------------------------------------- cards -- */
.pd2-r-rail .pd2-r-card{
  background:var(--pd2-bg); border:1px solid var(--pd2-line);
  border-radius:var(--pd2-r-lg); box-shadow:var(--pd2-shadow-sm);
}
.pd2-r-rail .pd2-r-price{
  padding:20px; border-color:var(--pd2-line-strong); box-shadow:var(--pd2-shadow-md);
}

/* ------------------------------------------------------------ price card -- */
.pd2-r-rail .pd2-r-rent{display:flex;align-items:baseline;gap:8px}
/* NOT var(--pd2-font-display). That token is 'Domine',Georgia,serif — W0 copied
   it from the prototype's h1/h2/h3 rule — but the prototype declares this
   element as `font-family:'Domine',serif`, and the difference is visible:
   Domine has no ₹ glyph, so the rupee sign falls through to the NEXT family in
   the stack. Georgia's ₹ is 7.6px wider than the default serif's at 31px, which
   shifts "/month" by the same amount and fails the ±1px geometry check. The
   prototype's own declaration wins over the token here. Same for .pd2-r-num. */
.pd2-r-rail .pd2-r-amt{
  font-family:'Domine',serif; font-size:31px; font-weight:700; letter-spacing:-.02em;
}
.pd2-r-rail .pd2-r-per{color:var(--pd2-ink-3);font-size:14px;font-weight:500}
.pd2-r-rail .pd2-r-neg{
  display:inline-flex;align-items:center;gap:6px;margin-top:9px;font-size:12.5px;
  font-weight:600;color:var(--pd2-green);background:var(--pd2-green-soft);
  padding:5px 10px;border-radius:8px;
}
.pd2-r-rail .pd2-r-split{
  display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:18px 0;padding:16px 0;
  border-top:1px solid var(--pd2-line);border-bottom:1px solid var(--pd2-line);
}
.pd2-r-rail .pd2-r-k{
  font-size:11.5px;color:var(--pd2-ink-3);text-transform:uppercase;
  letter-spacing:.05em;font-weight:600;
}
.pd2-r-rail .pd2-r-v{font-weight:600;font-size:14.5px;margin-top:3px}
/* A value we don't collect yet renders as a quiet dash, not a bold "—", so an
   incomplete listing doesn't read as a broken one. `security_deposit` has no
   column; the markup slot stays so it lights up the day the column exists. */
.pd2-r-rail .pd2-r-v-empty{color:var(--pd2-ink-3);font-weight:500}

/* ------------------------------------------------------------------ CTA -- */
.pd2-r-rail .pd2-r-btn{
  width:100%; background:var(--pd2-accent); color:#fff; font-weight:600; font-size:15.5px;
  padding:14px; border-radius:12px; display:flex; align-items:center; justify-content:center; gap:9px;
  box-shadow:0 4px 12px rgba(255,84,3,.28); transition:all .15s;
}
.pd2-r-rail .pd2-r-btn:hover{background:var(--pd2-accent-ink);box-shadow:0 6px 16px rgba(255,84,3,.34)}
.pd2-r-rail .pd2-r-btn[disabled]{opacity:.75;cursor:default}
.pd2-r-rail .pd2-r-btn[disabled]:hover{background:var(--pd2-accent);box-shadow:0 4px 12px rgba(255,84,3,.28)}
.pd2-r-rail .pd2-r-btn-ghost{
  width:100%; border:1.5px solid var(--pd2-line-strong); font-weight:600; font-size:14.5px;
  padding:12px; border-radius:12px; margin-top:10px; display:flex; align-items:center;
  justify-content:center; gap:9px;
}
.pd2-r-rail .pd2-r-btn-ghost:hover{background:var(--pd2-bg-soft)}
.pd2-r-rail .pd2-r-assure{
  display:flex;gap:9px;align-items:flex-start;margin-top:14px;font-size:12.5px;
  color:var(--pd2-ink-2);line-height:1.5;
}
.pd2-r-rail .pd2-r-assure i{color:var(--pd2-green);font-size:15px;margin-top:1px}
/* Endpoint said no (stale page — cap hit in another tab, session expired). */
.pd2-r-rail .pd2-r-err{
  display:flex;gap:9px;align-items:flex-start;margin-top:12px;font-size:12.5px;
  color:var(--pd2-amber);line-height:1.5;
}
.pd2-r-rail .pd2-r-err i{font-size:15px;margin-top:1px;flex:none}

/* --------------------------------------------------------- number reveal --
   The number is never in the initial HTML. Tapping the button hits the
   server, which re-checks entitlement, logs the reveal via
   trackInteraction(...,'contact') and returns the number. */
.pd2-r-rail .pd2-r-spin{
  width:16px;height:16px;border-radius:50%;flex:none;
  border:2px solid rgba(255,255,255,.4); border-top-color:#fff;
  animation:pd2-r-spin .7s linear infinite;
}
@keyframes pd2-r-spin{to{transform:rotate(360deg)}}

.pd2-r-rail .pd2-r-box{
  border:1.5px solid var(--pd2-green); border-radius:12px; overflow:hidden;
  background:var(--pd2-green-soft); animation:pd2-r-pop .28s cubic-bezier(.2,.9,.3,1);
}
@keyframes pd2-r-pop{from{opacity:0;transform:translateY(6px) scale(.985)}to{opacity:1;transform:none}}
.pd2-r-rail .pd2-r-box-label{
  font-size:10px;font-weight:700;letter-spacing:.09em;text-transform:uppercase;
  color:var(--pd2-green);padding:11px 14px 0;display:flex;align-items:center;gap:6px;
}
.pd2-r-rail .pd2-r-num{
  display:flex;align-items:center;justify-content:center;gap:10px;
  font-family:'Domine',serif;font-size:23px;font-weight:700;letter-spacing:.01em;
  color:var(--pd2-green);padding:8px 14px 14px;
}
.pd2-r-rail .pd2-r-num i{font-size:19px}
.pd2-r-rail .pd2-r-acts{
  display:grid;grid-template-columns:1fr 1fr;gap:1px;
  background:var(--pd2-green);border-top:1.5px solid var(--pd2-green);
}
.pd2-r-rail .pd2-r-act{
  background:var(--pd2-bg);padding:12px;text-align:center;font-weight:600;font-size:14px;
  display:flex;align-items:center;justify-content:center;gap:8px;color:var(--pd2-ink);
}
.pd2-r-rail .pd2-r-act:hover{background:var(--pd2-bg-soft)}
.pd2-r-rail .pd2-r-act-wa{color:#128C7E}
.pd2-r-rail .pd2-r-saved{
  display:flex;gap:8px;align-items:flex-start;margin-top:12px;font-size:12px;
  color:var(--pd2-ink-3);line-height:1.45;
}
.pd2-r-rail .pd2-r-saved i{font-size:14px;margin-top:1px}

/* ---------------------------------------------- money-back ribbon (idle) --
   Prototype `.g-ribbon` — the small inline version that lives in the price
   card. Shown to viewers who have not unlocked contact yet; it is the reason
   to pick LetsRentz, not just a paywall consolation. */
.pd2-r-rail .pd2-r-ribbon{
  display:flex;align-items:center;gap:10px;margin-top:14px;padding:11px 13px;
  border-radius:11px;background:var(--pd2-green-soft);border:1px solid var(--pd2-green-line);
}
.pd2-r-rail .pd2-r-ribbon i{color:var(--pd2-green);font-size:19px;flex:none}
.pd2-r-rail .pd2-r-ribbon-t{font-size:12.5px;font-weight:700;color:var(--pd2-green);line-height:1.3}
.pd2-r-rail .pd2-r-ribbon-s{font-size:11.5px;color:var(--pd2-ink-2);line-height:1.35;margin-top:2px}

/* ------------------------------------------------------- listed-by card -- */
.pd2-r-rail .pd2-r-lister{padding:18px}
.pd2-r-rail .pd2-r-lister-head{
  font-size:11px;letter-spacing:.07em;text-transform:uppercase;
  color:var(--pd2-ink-3);font-weight:700;margin-bottom:13px;
}
.pd2-r-rail .pd2-r-lister-row{display:flex;gap:12px;align-items:center}
.pd2-r-rail .pd2-r-lister-id{flex:1;min-width:0}
.pd2-r-rail .pd2-r-av{
  width:46px;height:46px;border-radius:50%;object-fit:cover;
  background:var(--pd2-bg-sunk);flex:none;
}
.pd2-r-rail .pd2-r-name{font-weight:600;font-size:15px}
.pd2-r-rail .pd2-r-meta{font-size:12.5px;color:var(--pd2-ink-3)}
.pd2-r-rail .pd2-r-meta i{color:var(--pd2-green)}
/* Blurred, not truncated: the shape of a real name is the signal, the name
   itself is the thing being withheld. */
.pd2-r-rail .pd2-r-masked{filter:blur(4px);user-select:none}
.pd2-r-rail .pd2-r-stats{
  display:flex;gap:18px;margin-top:14px;padding-top:14px;border-top:1px solid var(--pd2-line);
}
.pd2-r-rail .pd2-r-stat-n{font-weight:600;font-size:15px}
.pd2-r-rail .pd2-r-stat-l{font-size:11.5px;color:var(--pd2-ink-3)}
.pd2-r-rail .pd2-r-profile{
  display:flex;align-items:center;justify-content:center;gap:7px;margin-top:13px;
  padding:10px;border:1.5px solid var(--pd2-line-strong);border-radius:10px;
  font-size:13.5px;font-weight:600;color:var(--pd2-ink);
}
.pd2-r-rail .pd2-r-profile:hover{background:var(--pd2-bg-soft);border-color:var(--pd2-ink-3)}
.pd2-r-rail .pd2-r-fee{
  display:flex;gap:9px;align-items:flex-start;margin-top:13px;padding-top:13px;
  border-top:1px solid var(--pd2-line);font-size:12px;color:var(--pd2-amber);line-height:1.45;
}
.pd2-r-rail .pd2-r-fee i{font-size:14px;margin-top:1px;flex:none}

/* ----------------------------------------------------------- safety note -- */
.pd2-r-rail .pd2-r-safety{
  padding:15px 18px;background:var(--pd2-bg-soft);border:1px solid var(--pd2-line);
  border-radius:var(--pd2-r-md);font-size:12.5px;color:var(--pd2-ink-2);
  display:flex;gap:10px;line-height:1.55;
}
.pd2-r-rail .pd2-r-safety i{color:var(--pd2-ink-3);font-size:16px;margin-top:1px}

/* ============================================================ responsive ==
   Ported verbatim from the prototype's @media (max-width:1000px):
     .rail{position:static; order:2; margin-top:8px}
     .rail .price-card{display:none}
   Below 1000px the rail stops floating and drops under the content, and the
   price card is dropped because W7's sticky bottom bar carries rent + CTA.
   ========================================================================= */
@media (max-width:1000px){
  .pd2-r-col{position:static;order:2;margin-top:8px}
  .pd2-r-rail .pd2-r-price{display:none}
}
