/* RoboList application components — extends the design system in rl-design.css
   using the same tokens (never overrides storefront styles). Covers modal,
   toast, forms, buttons, panels, tables, badges used by the built-out pages. */

/* Enforce the hidden attribute even on flex/grid components. */
[hidden] { display: none !important; }

/* ── Buttons ──────────────────────────────────────────────────────────────── */
.rl-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid var(--line-2); background: var(--white); color: var(--ink);
  border-radius: var(--r-md); padding: 10px 16px; font-size: 14px; font-weight: 600;
  letter-spacing: -0.01em; font-family: inherit; cursor: pointer; text-decoration: none;
  transition: border-color .12s, background .12s, transform .1s;
}
.rl-btn:hover { border-color: var(--subtle); }
.rl-btn:active { transform: translateY(1px); }
.rl-btn svg { width: 17px; height: 17px; }
.rl-btn-primary { background: var(--teal); border-color: var(--teal); color: #fff; }
.rl-btn-primary:hover { background: var(--teal-deep); border-color: var(--teal-deep); }
.rl-btn-ghost { background: transparent; border-color: transparent; color: var(--teal-dark); }
.rl-btn-ghost:hover { background: var(--teal-tint); }
.rl-btn-danger { background: #fff; border-color: #e5c2bd; color: #b3402f; }
.rl-btn-danger:hover { background: #fbeeec; }
.rl-btn-sm { padding: 7px 12px; font-size: 13px; }
.rl-btn-block { width: 100%; }
.rl-btn:disabled { opacity: .55; cursor: not-allowed; }

/* ── Panels ───────────────────────────────────────────────────────────────── */
.rl-panel { background: var(--white); border: 1px solid var(--line-2); border-radius: var(--r-lg); box-shadow: 0 1px 2px rgba(18,20,20,.05); }
.rl-panel-pad { padding: 20px 22px; }
.rl-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.rl-panel-head h3 { font-size: 16px; font-weight: 700; letter-spacing: -0.02em; }
.rl-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.rl-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 860px){ .rl-grid-2, .rl-grid-3 { grid-template-columns: 1fr; } }

/* ── Forms ────────────────────────────────────────────────────────────────── */
.rl-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.rl-field > span { font-size: 13px; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; }
.rl-input, .rl-select, .rl-textarea {
  width: 100%; border: 1px solid var(--line-2); background: var(--white); color: var(--ink);
  border-radius: var(--r-md); padding: 10px 12px; font-size: 14.5px; font-family: inherit;
  letter-spacing: -0.01em; transition: border-color .15s, box-shadow .15s;
}
.rl-input:focus, .rl-select:focus, .rl-textarea:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px var(--teal-tint); }
.rl-textarea { resize: vertical; min-height: 90px; }
.rl-help { font-size: 12px; color: var(--muted); }

/* ── Badges / status pills ───────────────────────────────────────────────── */
.rl-badge { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 700; letter-spacing: .02em; padding: 3px 9px; border-radius: 999px; background: var(--teal-tint); color: var(--teal-dark); text-transform: uppercase; }
.rl-badge-ok { background: #e3f3ea; color: #1f7a4d; }
.rl-badge-warn { background: #f6eccf; color: #8a6d1a; }
.rl-badge-info { background: #e6eef7; color: #1b4f7a; }
.rl-badge-muted { background: var(--sand); color: var(--muted); }
.rl-badge-danger { background: #fbe4e0; color: #b3402f; }

/* ── Tabs ─────────────────────────────────────────────────────────────────── */
.rl-tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); margin-bottom: 22px; flex-wrap: wrap; }
.rl-tab { padding: 10px 14px; font-size: 14px; font-weight: 600; color: var(--muted); background: none; border: none; border-bottom: 2px solid transparent; cursor: pointer; letter-spacing: -0.01em; }
.rl-tab:hover { color: var(--ink); }
.rl-tab.active { color: var(--teal-dark); border-bottom-color: var(--teal); }

/* ── Tables ───────────────────────────────────────────────────────────────── */
.rl-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.rl-table th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--subtle); font-weight: 700; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.rl-table td { padding: 12px; border-bottom: 1px solid var(--line); color: var(--ink); }
.rl-table tr:hover td { background: var(--paper); }

/* ── Empty / loading ──────────────────────────────────────────────────────── */
.rl-empty { grid-column: 1 / -1; text-align: center; padding: 60px 20px; color: var(--muted); }
.rl-empty-ic { width: 56px; height: 56px; margin: 0 auto 14px; color: #c2ccca; }
.rl-empty-ic svg { width: 100%; height: 100%; }
.rl-empty h3 { font-size: 17px; color: var(--ink); font-weight: 700; margin-bottom: 4px; letter-spacing: -0.02em; }
.rl-empty p { font-size: 14px; }
.rl-skel { background: linear-gradient(90deg, #eee 25%, #f5f5f3 37%, #eee 63%); background-size: 400% 100%; animation: rlsk 1.3s ease infinite; border-radius: var(--r-md); }
@keyframes rlsk { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }

/* ── Section heading ─────────────────────────────────────────────────────── */
.rl-section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 8px 0 18px; }
.rl-section-head h2 { font-size: 20px; font-weight: 700; letter-spacing: -0.025em; }

/* ── Modal ────────────────────────────────────────────────────────────────── */
.rl-modal-overlay { position: fixed; inset: 0; background: rgba(15,28,28,.42); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; z-index: 1000; padding: 20px; }
.rl-modal-overlay[hidden] { display: none; }
.rl-modal { background: var(--white); border-radius: var(--r-xl); width: 100%; max-width: 420px; padding: 30px 30px 26px; position: relative; box-shadow: 0 24px 70px rgba(0,40,40,.28); animation: rlin .2s ease; }
@keyframes rlin { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.rl-modal-x { position: absolute; top: 14px; right: 16px; border: none; background: none; font-size: 24px; line-height: 1; color: var(--subtle); cursor: pointer; }
.rl-modal-x:hover { color: var(--ink); }
.rl-modal-brand { margin-bottom: 14px; }
.rl-modal-brand .wm { font-size: 24px; font-weight: 500; letter-spacing: -0.03em; color: #1A4D43; }
.rl-modal-brand .wm .x { font-weight: 700; }
.rl-modal h2 { font-size: 22px; font-weight: 700; letter-spacing: -0.03em; margin-bottom: 4px; }
.rl-modal-sub { font-size: 14px; color: var(--muted); margin-bottom: 20px; }
.rl-modal .rl-btn-primary.rl-btn, #rl-auth-submit { width: 100%; }
#rl-auth-submit { margin-top: 4px; width: 100%; background: var(--teal); border: none; color: #fff; border-radius: var(--r-md); padding: 11px; font-size: 14.5px; font-weight: 700; cursor: pointer; font-family: inherit; letter-spacing: -0.01em; }
#rl-auth-submit:hover { background: var(--teal-deep); }
.rl-auth-alt { display: flex; justify-content: space-between; margin-top: 16px; font-size: 13px; }
.rl-auth-alt a { color: var(--teal); text-decoration: none; }
.rl-auth-alt a:hover { text-decoration: underline; }
.rl-auth-legal { margin: 4px 0 14px; font-size: 12px; color: var(--muted); line-height: 1.55; display:flex; align-items:flex-start; gap:8px; cursor:pointer; }
.rl-auth-legal[hidden] { display:none; }
.rl-auth-legal input { margin-top:3px; accent-color:var(--teal); }
.rl-auth-legal a { color: var(--teal); text-decoration: none; }
.rl-auth-legal a:hover { text-decoration: underline; }

/* ── Sidebar legal links ──────────────────────────────────────────────────── */
.sb-legal { display: flex; align-items: center; justify-content: center; gap: 7px; padding: 10px 4px 2px; font-size: 11.5px; color: var(--subtle); }
.sb-legal a { color: var(--subtle); text-decoration: none; }
.sb-legal a:hover { color: var(--ink); text-decoration: underline; }
.rl-auth-err { margin-top: 14px; padding: 10px 12px; border-radius: var(--r-sm); background: #fbe4e0; color: #b3402f; font-size: 13px; }

.rl-btn.disabled { opacity: .5; pointer-events: none; }

/* ── Toasts ───────────────────────────────────────────────────────────────── */
#rl-toasts { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 1100; align-items: center; }
.rl-toast { background: var(--teal-dark); color: #fff; padding: 11px 18px; border-radius: 999px; font-size: 13.5px; font-weight: 600; box-shadow: 0 8px 24px rgba(0,40,40,.25); opacity: 0; transform: translateY(10px); transition: opacity .25s, transform .25s; }
.rl-toast.show { opacity: 1; transform: none; }
.rl-toast-err { background: #b3402f; }

/* ── Detail layout (listing / service) ───────────────────────────────────── */
.rl-detail { display: grid; grid-template-columns: 1.1fr .9fr; gap: 30px; align-items: start; }
@media (max-width: 900px){ .rl-detail { grid-template-columns: 1fr; } }
.rl-gallery { background: var(--white); border: 1px solid var(--line-2); border-radius: var(--r-lg); aspect-ratio: 4/3; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.rl-gallery img { width: 100%; height: 100%; object-fit: contain; }
.rl-gallery .ico { width: 96px; height: 96px; color: #c2ccca; }
.rl-price-lg { font-size: 38px; font-weight: 800; color: #014345; letter-spacing: -0.03em; }
.rl-price-lg .was { font-size: 18px; font-weight: 400; color: var(--subtle); text-decoration: line-through; margin-left: 10px; }

/* ── Messages layout ──────────────────────────────────────────────────────── */
.rl-msg-wrap { display: grid; grid-template-columns: 320px 1fr; gap: 0; border: 1px solid var(--line-2); border-radius: var(--r-lg); overflow: hidden; background: var(--white); height: calc(100vh - 220px); min-height: 440px; }
@media (max-width: 820px){ .rl-msg-wrap { grid-template-columns: 1fr; } }
.rl-thread-list { border-right: 1px solid var(--line); overflow-y: auto; }
.rl-thread { display: flex; gap: 10px; padding: 13px 16px; border-bottom: 1px solid var(--line); cursor: pointer; }
.rl-thread:hover, .rl-thread.active { background: var(--paper); }
.rl-thread .ava { width: 38px; height: 38px; border-radius: 10px; background: var(--teal); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; flex: none; font-size: 13px; }
.rl-chat { display: flex; flex-direction: column; min-width: 0; }
.rl-chat-scroll { flex: 1; overflow-y: auto; padding: 18px; display: flex; flex-direction: column; gap: 10px; }
.rl-bubble { max-width: 70%; padding: 9px 13px; border-radius: 14px; font-size: 14px; line-height: 1.4; }
.rl-bubble.them { background: var(--sand); align-self: flex-start; border-bottom-left-radius: 4px; }
.rl-bubble.me { background: var(--teal); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.rl-bubble img { max-width: 200px; border-radius: 8px; display: block; }
.rl-chat-input { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); }
.rl-offer-card { border: 1px solid var(--line-2); border-radius: var(--r-md); padding: 12px 14px; background: var(--teal-tint); align-self: flex-start; max-width: 80%; }

/* ── Stat tiles ───────────────────────────────────────────────────────────── */
.rl-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 26px; }
@media (max-width: 860px){ .rl-stats { grid-template-columns: repeat(2,1fr);} }
.rl-stat { background: var(--white); border: 1px solid var(--line-2); border-radius: var(--r-lg); padding: 16px 18px; }
.rl-stat .v { font-size: 26px; font-weight: 800; letter-spacing: -0.03em; color: var(--teal-dark); }
.rl-stat .l { font-size: 12.5px; color: var(--muted); margin-top: 2px; }

/* ── Upload drop slot ─────────────────────────────────────────────────────── */
.rl-drop { border: 2px dashed var(--line-2); border-radius: var(--r-lg); padding: 26px; text-align: center; color: var(--muted); cursor: pointer; transition: border-color .15s, background .15s; }
.rl-drop:hover, .rl-drop.drag { border-color: var(--teal); background: var(--teal-tint); }
.rl-thumbs { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.rl-thumb { width: 70px; height: 70px; border-radius: var(--r-sm); overflow: hidden; position: relative; border: 1px solid var(--line); }
.rl-thumb img { width: 100%; height: 100%; object-fit: cover; }
.rl-thumb button { position: absolute; top: 2px; right: 2px; background: rgba(0,0,0,.6); color: #fff; border: none; border-radius: 50%; width: 18px; height: 18px; cursor: pointer; font-size: 12px; line-height: 1; }

/* ── App shell responsive behavior ───────────────────────────────────────── */
@media (max-width: 760px) {
  .app {
    flex-direction: column;
    height: 100dvh;
  }

  .sidebar {
    width: 100%;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 12px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand action"
      "nav nav";
    gap: 10px 12px;
  }

  .brand {
    grid-area: brand;
    min-width: 0;
    padding: 0;
  }

  .brand img {
    height: 26px !important;
  }

  .brand .wm {
    font-size: 24px;
    white-space: nowrap;
  }

  .new-btn {
    grid-area: action;
    align-self: center;
    width: auto;
    margin: 0;
    padding: 10px 12px;
    white-space: nowrap;
  }

  .nav {
    grid-area: nav;
    flex-direction: row;
    gap: 6px;
    margin: 0;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  .nav::-webkit-scrollbar {
    display: none;
  }

  .nav-label,
  .sb-spacer,
  .sb-foot,
  .sb-legal {
    display: none;
  }

  .nav a {
    flex: 0 0 auto;
    gap: 8px;
    padding: 8px 10px;
    font-size: 13.5px;
  }

  .nav a svg {
    width: 18px;
    height: 18px;
  }

  .main {
    flex: 1;
    min-height: 0;
    width: 100%;
    scrollbar-gutter: auto;
  }

  .content {
    max-width: none;
    padding: 16px 14px 56px;
  }

  .content-top {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    margin-bottom: 22px;
  }

  .content-top .topsearch[style*="visibility:hidden"] {
    display: none;
  }

  .topsearch {
    width: 100%;
    max-width: none;
    flex: none;
  }

  .topright {
    width: 100%;
    margin-left: 0;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .page-head h1 {
    font-size: 34px;
  }

  .feed {
    margin-top: 34px;
  }

  .feed-head,
  .filterbar,
  .rl-section-head,
  .rl-panel-head {
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 10px;
  }

  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .sale-banner {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .rl-filter-row .rl-select,
  .rl-filter-row .rl-input {
    width: 100%;
  }

  .rl-price-range {
    width: 100%;
  }

  .rl-price-range .rl-input {
    flex: 1;
    width: 0;
  }

  .rl-table {
    min-width: 620px;
  }

  .rl-panel:has(.rl-table) {
    overflow-x: auto;
  }
}

@media (max-width: 520px) {
  .grid {
    grid-template-columns: 1fr;
  }

  .page-head h1 {
    font-size: 32px;
  }
}

@media (max-width: 360px) {
  .new-btn {
    width: 42px;
    height: 40px;
    justify-content: center;
    padding: 0;
    overflow: hidden;
    font-size: 0;
  }
}

/* ── Notification bell + dropdown ──────────────────────────────────────────── */
.rl-notif { position: relative; display: inline-flex; }
.rl-notif-btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border: 1px solid var(--line-2); background: var(--white);
  border-radius: 999px; color: var(--ink); cursor: pointer;
}
.rl-notif-btn:hover { border-color: var(--teal); color: var(--teal-dark); }
.rl-notif-btn svg { width: 18px; height: 18px; display: block; }
.rl-notif-badge {
  position: absolute; top: -3px; right: -3px; min-width: 17px; height: 17px; padding: 0 4px;
  border-radius: 999px; background: #d8543f; color: #fff; font-size: 10.5px; font-weight: 700;
  line-height: 17px; text-align: center; box-shadow: 0 0 0 2px var(--white);
}
.rl-notif-panel {
  position: absolute; top: 46px; right: 0; width: 340px; max-width: 86vw; max-height: 420px;
  overflow: auto; background: var(--white); border: 1px solid var(--line-2);
  border-radius: var(--r-lg); box-shadow: 0 18px 50px rgba(0, 40, 40, 0.22); z-index: 1200; padding: 6px;
}
.rl-notif-item { display: block; padding: 10px 12px; border-radius: var(--r-md); text-decoration: none; color: inherit; }
.rl-notif-item:hover { background: var(--paper); }
.rl-notif-item.unread { background: var(--teal-tint); }
.rl-notif-item.unread:hover { background: #d9efe9; }
.rl-notif-row { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.rl-notif-row b { font-size: 13.5px; letter-spacing: -0.01em; }
.rl-notif-row span { font-size: 11px; color: var(--muted); flex: none; }
.rl-notif-b { font-size: 12.5px; color: var(--muted); margin-top: 2px; line-height: 1.4; }
.rl-notif-empty { padding: 24px 14px; text-align: center; font-size: 13px; color: var(--muted); }

/* ── Auth modal: Google button, divider, password show/hide ────────────────── */
.rl-auth-modal { max-width: 540px; padding: clamp(28px, 5vw, 42px); border: 1px solid rgba(0,66,67,.08); }
.rl-auth-modal .rl-modal-brand .wm { font-size: 30px; }
.rl-auth-modal h2 { font-size: clamp(27px, 5vw, 34px); margin-top: 20px; }
.rl-auth-modal .rl-modal-sub { font-size: 16px; line-height: 1.55; margin-bottom: 24px; }
.rl-auth-modal .rl-field { gap: 8px; margin-bottom: 18px; }
.rl-auth-modal .rl-field > span { font-size: 14px; font-weight: 700; }
.rl-auth-modal .rl-input, .rl-auth-modal .rl-pw > input {
  min-height: 54px; padding: 14px 16px; border: 1.5px solid var(--line-2);
  border-radius: 14px; font: 500 16px/1.3 var(--font); background: #fff;
}
.rl-auth-modal .rl-pw > input { padding-right: 72px; }
.rl-auth-modal .rl-input:hover, .rl-auth-modal .rl-pw > input:hover { border-color: #a9aaa5; }
.rl-auth-modal .rl-input:focus, .rl-auth-modal .rl-pw > input:focus { outline: 0; border-color: var(--teal); box-shadow: 0 0 0 4px var(--teal-tint); }
.rl-auth-modal #rl-auth-submit { min-height: 54px; border-radius: 14px; font-size: 16px; margin-top: 8px; transition: background .15s, transform .1s, opacity .15s; }
.rl-auth-modal #rl-auth-submit:focus-visible, .rl-auth-modal a:focus-visible, .rl-pw-toggle:focus-visible { outline: 3px solid #83b8ad; outline-offset: 3px; }
.rl-auth-modal #rl-auth-submit:disabled { opacity: .5; cursor: not-allowed; }
.rl-auth-modal .rl-auth-alt { margin-top: 20px; font-size: 14px; gap: 18px; flex-wrap: wrap; }
.rl-auth-modal .rl-auth-legal { display: none !important; }
.rl-google-wrap { margin: 16px 0 2px; }
#rl-google-btn { display: flex; justify-content: center; min-height: 40px; color-scheme: light; }
.rl-or { display: flex; align-items: center; gap: 12px; margin: 16px 0 4px; color: var(--muted); font-size: 12px; font-weight: 600; letter-spacing: .02em; text-transform: uppercase; }
.rl-or::before, .rl-or::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.rl-pw { position: relative; display: block; }
.rl-pw > input { width: 100%; padding-right: 62px; }
.rl-pw-toggle {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  border: none; background: none; color: var(--teal-dark); font-size: 12.5px; font-weight: 700;
  cursor: pointer; padding: 5px 8px; border-radius: 6px;
}
.rl-pw-toggle:hover { background: var(--teal-tint); }

/* ── Floating contact support ────────────────────────────────────────────── */
.rl-support { position: fixed; right: 24px; bottom: 22px; z-index: 900; font-family: var(--font); }
.rl-support-bubble {
  position: relative; margin-left: auto; width: 58px; height: 58px; border: 0; border-radius: 50%;
  display: grid; place-items: center; background: var(--teal); color: #fff; cursor: pointer;
  box-shadow: 0 12px 30px rgba(0,66,67,.32); transition: transform .16s, background .16s, box-shadow .16s;
}
.rl-support-bubble:hover { background: var(--teal-deep); transform: translateY(-2px); box-shadow: 0 16px 36px rgba(0,66,67,.38); }
.rl-support-bubble:focus-visible { outline: 4px solid #9bc8bf; outline-offset: 3px; }
.rl-support-bubble svg { width: 25px; height: 25px; }
.rl-support.open .rl-support-bubble svg { transform: scale(.92); }
.rl-support-ping { position: absolute; top: 3px; right: 3px; width: 13px; height: 13px; border-radius: 50%; background: #d8ef7c; border: 3px solid var(--teal); }
.rl-support-card {
  position: absolute; right: 0; bottom: 72px; width: min(350px,calc(100vw - 32px)); padding: 20px;
  border: 1px solid rgba(0,66,67,.12); border-radius: 20px; background: #fff;
  box-shadow: 0 22px 60px rgba(12,40,38,.24); animation: rlsupportin .18s ease;
}
@keyframes rlsupportin { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
.rl-support-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.rl-support-head h2 { margin: 4px 0 0; font-size: 22px; line-height: 1.15; letter-spacing: -.035em; }
.rl-support-close { border: 0; background: transparent; color: var(--subtle); font-size: 24px; line-height: 1; cursor: pointer; padding: 2px 4px; border-radius: 6px; }
.rl-support-close:hover { color: var(--ink); background: var(--paper); }
.rl-support-close:focus-visible { outline: 3px solid var(--teal-tint2); }
.rl-support-card > p { margin: 12px 0 16px; color: var(--muted); font-size: 13.5px; line-height: 1.55; }
.rl-support-option { display: grid; grid-template-columns:38px 1fr auto; align-items: center; gap: 10px; padding: 11px; margin-top: 9px; border: 1px solid var(--line); border-radius: 13px; color: var(--ink); text-decoration: none; transition: border-color .14s, background .14s, transform .14s; }
.rl-support-option:hover { border-color: #a9c6c1; background: var(--teal-tint); transform: translateY(-1px); }
.rl-support-option:focus-visible { outline: 3px solid #9bc8bf; outline-offset: 2px; }
.rl-support-option-icon { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 11px; background: var(--teal-tint); color: var(--teal-dark); font-weight: 800; font-size: 18px; }
.rl-support-instagram { background: linear-gradient(145deg,#f6d7ed,#f7e7bd); color: #8b3d75; }
.rl-support-option span:nth-child(2) { min-width: 0; }
.rl-support-option b { display: block; font-size: 13.5px; }
.rl-support-option small { display: block; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11.5px; }
.rl-support-note { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11.5px; line-height: 1.5; }

/* ── Legal page + mandatory versioned acceptance ─────────────────────────── */
.legal-wrap { max-width: 940px; margin: 0 auto; padding-bottom: 50px; }
.legal-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-xl); padding: clamp(24px,5vw,52px); box-shadow: var(--shadow-sm); }
.legal-intro h1 { font-size: clamp(32px,5vw,50px); line-height: 1.05; letter-spacing: -.05em; margin: 6px 0 14px; }
.legal-intro p { max-width: 700px; color: var(--muted); font-size: 16px; line-height: 1.7; }
.legal-kicker, .liability-label { color: var(--teal-dark); font: 700 11px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .08em; }
.term { padding: 18px 0; border-bottom: 1px solid var(--line); }
.term h2 { font-size: 17px; line-height: 1.4; margin: 0 0 7px; }
.term p { color: var(--muted); font-size: 14px; line-height: 1.7; margin: 0; }
.liability { margin: 32px 0 22px; padding: clamp(22px,4vw,38px); border: 3px solid var(--teal-dark); border-radius: 22px; background: linear-gradient(145deg,#e2f1ec,#fff 70%); box-shadow: 0 14px 36px rgba(0,66,67,.12); }
.liability h2 { color: #063f37; font-size: clamp(23px,3.7vw,31px); line-height: 1.2; letter-spacing: -.03em; margin: 9px 0 18px; }
.liability p { color: var(--ink); font-size: 16px; line-height: 1.72; margin: 0 0 15px; }
.liability p:last-child { margin-bottom: 0; }
.liability .lead { font-size: 18px; line-height: 1.6; }
.secondary-terms { opacity: .88; padding: 0 8px; }

.rl-terms-gate { z-index: 1800; padding: 0; background: rgba(4,24,23,.78); }
.rl-terms-dialog { width: min(960px,100%); max-width: none; height: min(900px,100dvh); border-radius: 24px; padding: 0; display: grid; grid-template-rows:auto minmax(0,1fr) auto; overflow: hidden; }
.rl-terms-head { padding: 22px clamp(20px,4vw,38px) 16px; border-bottom: 1px solid var(--line); }
.rl-terms-head h2 { font-size: clamp(23px,4vw,32px); }
.rl-terms-head p { color: var(--muted); margin-top: 4px; }
.rl-terms-scroll { overflow: auto; padding: 24px clamp(18px,4vw,42px) 48px; scroll-behavior: smooth; }
.rl-terms-scroll .legal-intro h1 { font-size: clamp(27px,4vw,40px); }
.rl-terms-foot { border-top: 1px solid var(--line); padding: 16px clamp(18px,4vw,38px); background: #fff; }
.rl-scroll-hint { font-size: 12px; color: var(--muted); margin-bottom: 10px; text-align: center; }
.rl-terms-confirm { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; line-height: 1.45; font-weight: 600; cursor: pointer; }
.rl-terms-confirm input { width: 18px; height: 18px; margin-top: 1px; accent-color: var(--teal); flex: none; }
.rl-terms-actions { display: flex; align-items: center; gap: 12px; margin-top: 13px; }
.rl-terms-actions .rl-btn-primary { flex: 1; min-height: 50px; }

/* ── Reporting form ──────────────────────────────────────────────────────── */
.rl-report-modal .rl-modal { max-width: 600px; max-height: calc(100dvh - 32px); overflow: auto; }
.rl-report-attached { margin: -8px 0 16px; padding: 11px 13px; border-radius: var(--r-md); background: var(--teal-tint); color: var(--teal-dark); font-size: 13px; }
.rl-report-success { padding: 30px 12px; text-align: center; }
.rl-report-success .check { width: 54px; height: 54px; margin: 0 auto 14px; border-radius: 50%; display: grid; place-items: center; background: #e3f3ea; color: #1f7a4d; font-size: 26px; }

@media (max-width: 600px) {
  .rl-modal-overlay { padding: 10px; align-items: flex-end; }
  .rl-auth-modal { max-width: none; border-radius: 22px 22px 0 0; padding: 30px 22px max(24px,env(safe-area-inset-bottom)); }
  .rl-terms-dialog { height: 100dvh; border-radius: 0; }
  .rl-terms-actions { align-items: stretch; flex-direction: column-reverse; }
  .rl-terms-actions .rl-btn { width: 100%; }
  .rl-support { right: 14px; bottom: max(14px,env(safe-area-inset-bottom)); }
  .rl-support-bubble { width: 54px; height: 54px; }
  .rl-support-card { right: 0; bottom: 66px; width: min(350px,calc(100vw - 28px)); }
}

/* ── Email-verification banner ─────────────────────────────────────────────── */
#rl-verify-banner {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin: 0 0 16px; padding: 10px 14px; border-radius: var(--r-md);
  background: #f6eccf; border: 1px solid #ead9aa; color: #6f5a17; font-size: 13.5px; font-weight: 500;
}
#rl-verify-banner [data-rl-resend] { color: #6f5a17; font-weight: 700; text-decoration: underline; background: none; border: none; cursor: pointer; font-size: 13.5px; }
#rl-verify-banner .rl-verify-x { margin-left: auto; background: none; border: none; font-size: 18px; line-height: 1; color: #8a7733; cursor: pointer; padding: 0 4px; }

/* ── Watchlist remove control ──────────────────────────────────────────────── */
.rl-watch-item { position: relative; }
.rl-watch-remove {
  position: absolute; top: 10px; right: 10px; width: 28px; height: 28px; z-index: 2;
  display: flex; align-items: center; justify-content: center; border: none; border-radius: 999px;
  background: rgba(15, 28, 28, 0.55); color: #fff; font-size: 14px; line-height: 1; cursor: pointer;
  backdrop-filter: blur(2px);
}
.rl-watch-remove:hover { background: #b3402f; }
#rl-toasts .rl-toast { display:flex; align-items:center; gap:10px; }
.brand { text-decoration:none; }
#rl-toasts .rl-toast span { flex:1; }
#rl-toasts .rl-toast button { border:0; background:transparent; color:inherit; font-size:18px; cursor:pointer; padding:0 2px; }
.rl-upload-status { margin-top:8px; font-size:12px; }
.rl-upload-row { display:flex; align-items:center; gap:8px; color:var(--muted); }
.rl-upload-row span:first-child { max-width:220px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.rl-upload-row progress { width:100px; accent-color:var(--teal); }
.rl-upload-row.ok { color:var(--teal-dark); }
.rl-upload-row.err { color:#a33434; }
