/* Rede Secreta — Rubri Noctis: camara intima de vinho e rubi.
   Escopo local em .rs-page para nao afetar o restante do app. */
.rs-page {
  --wine: #2a0f18;
  --ruby: #8b1e2f;
  --ruby-bright: #b52a42;
  --bronze: #c89b6a;
  --bronze-soft: #dfb27c;
  --bronze-bright: #e3b77e;
  --rs-gold: var(--bronze);
  --rs-gold-soft: var(--bronze-soft);
  --rs-gold-bright: var(--bronze-bright);
  --rs-text: #f5e9e6;
  box-sizing: border-box;
  width: 100%;
  min-height: 100dvh;
  padding: 36px 86px 100px;
  position: relative;
  overflow: hidden;
  color: var(--rs-text);
  background:
    radial-gradient(1000px 560px at 52% 0%, #451421 0%, transparent 72%),
    linear-gradient(160deg, #0d0a0c, #1b0c12 48%, #100b0e);
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  animation: rs-bloom 1.1s cubic-bezier(.18, .72, .2, 1) both;
}

.rs-top {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #c89b6a45;
  animation: rs-rise .8s ease .12s both;
}
.rs-mark {
  width: 43px; height: 43px;
  border: 1px solid var(--bronze);
  border-radius: 50%;
  display: grid; place-items: center;
  box-shadow: 0 0 24px #8b1e2f60;
  text-decoration: none;
}
.rs-mark::before {
  content: ""; width: 15px; height: 15px;
  border: 1px solid #e1bc88; border-radius: 50%;
  box-shadow: 0 0 0 5px #c89b6a1c;
}
.rs-nav { display: flex; align-items: center; gap: 12px; }
.rs-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #b52a42; box-shadow: 0 0 16px #e8445f;
  animation: rs-pulse 3s ease-in-out infinite;
}
.rs-pill {
  display: inline-flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 18px;
  border: 1px solid #c89b6a55; border-radius: 30px;
  background: #2a0f18; color: var(--rs-text);
  font-size: 13px; letter-spacing: .02em;
  text-decoration: none; cursor: pointer;
  transition: background .2s ease, box-shadow .2s ease;
}
.rs-pill:hover { background: #491523; box-shadow: 0 0 18px #8b1e2f55; }
.rs-pill:active { transform: scale(.98); }

.rs-hero {
  height: 580px;
  position: relative;
  margin-top: 30px;
  overflow: hidden;
  border: 1px solid #c89b6a65;
  border-radius: 28px;
  background: #210d14;
  box-shadow: 0 30px 90px #050306a8;
  animation: rs-rise .9s ease .2s both;
}
.rs-hero img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; -o-object-fit: cover; object-fit: cover;
  filter: brightness(.62) saturate(.72);
}
.rs-scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(112deg, #180910e8 0%, #631929a8 42%, #17091028 82%),
    linear-gradient(0deg, #0d0a0cc9, transparent 65%);
}
.rs-hero-art {
  position: absolute; right: 106px; top: 48px;
  width: 340px; height: 470px;
  border: 1px solid #d8aa755c;
  border-radius: 190px 190px 26px 26px;
  background: linear-gradient(155deg, #b72c4524, #2a0f1870);
  box-shadow: inset 0 1px 24px #ffffff22, 0 22px 70px #10050a88;
  backdrop-filter: blur(8px);
  animation: rs-float 7s ease-in-out infinite;
  pointer-events: none;
}
.rs-hero-art::before, .rs-hero-art::after {
  content: ""; position: absolute;
  border: 1px solid #d4a56c66; border-radius: 50%;
  left: 50%; top: 45%; transform: translate(-50%, -50%);
}
.rs-hero-art::before { width: 210px; height: 210px; }
.rs-hero-art::after { width: 152px; height: 152px; border-color: #e6ba8277; box-shadow: 0 0 60px #a8273c44; }
.rs-hero-content {
  position: absolute; left: 70px; bottom: 54px;
  width: min(600px, 60%);
  padding: 28px 32px; box-sizing: border-box;
  border: 1px solid #d8aa7566; border-radius: 24px;
  background: linear-gradient(135deg, #210e17e8, #35111dc9);
  backdrop-filter: blur(22px);
  box-shadow: 0 24px 70px #080407aa, inset 0 1px #ffffff20;
}
.rs-ornament { height: 1px; width: 100%; background: linear-gradient(90deg, #c89b6a, transparent); margin-top: 22px; }
.rs-hero-content::before {
  content: ""; display: block; width: 36px; height: 36px;
  border: 1px solid #c89b6a; border-radius: 50%;
  box-shadow: inset 0 0 0 6px #c89b6a1b, 0 0 24px #c89b6a44;
}
.rs-eyebrow { margin: 16px 0 0; color: #e1b881; font-size: 12px; letter-spacing: .23em; text-transform: uppercase; }
.rs-hero-title {
  margin: 8px 0 0;
  font-family: Georgia, "Cormorant Garamond", serif;
  font-size: clamp(28px, 3vw, 48px);
  line-height: 1.06; font-weight: 500; letter-spacing: -.02em;
  color: #fff2ec;
}
.rs-hero-title::first-letter {
  color: #d2a269; font-size: 1.28em; float: left;
  line-height: .9; margin-right: 7px;
}
.rs-hero-sub { margin: 14px 0 0; color: #ead8d6; font-size: 15px; line-height: 1.65; max-width: 49ch; }
.rs-cta {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 46px; margin-top: 22px; padding: 0 25px;
  border: 1px solid #d9ad78; border-radius: 30px;
  background: linear-gradient(135deg, #a5263b, #c44453);
  color: #fff4ed; font-weight: 700; letter-spacing: .02em;
  text-decoration: none; cursor: pointer;
  box-shadow: 0 12px 36px #8b1e2f66;
  transition: background .2s ease, box-shadow .2s ease, transform .2s ease;
}
.rs-cta:hover { background: linear-gradient(135deg, #bd3148, #d25d64); box-shadow: 0 16px 42px #9e263d88; transform: translateY(-2px); }
.rs-cta:active { transform: scale(.98); }
.rs-cta:focus-visible, .rs-pill:focus-visible, .rs-card:focus-visible { outline: 2px solid #e3b77e; outline-offset: 4px; }

.rs-section {
  margin-top: 68px;
  padding: 36px;
  border: 1px solid #8f53604d;
  border-radius: 26px;
  background: linear-gradient(135deg, #261019ef, #190d13f5);
  box-shadow: 0 20px 56px #07040777, inset 0 1px #ffffff0c;
  animation: rs-rise .85s ease both;
}
.rs-section:nth-of-type(3) { animation-delay: .28s; }
.rs-section:nth-of-type(4) { animation-delay: .4s; }
.rs-section:nth-of-type(5) { animation-delay: .52s; }
.rs-section-title { margin: 0 0 25px; color: #dfb27c; font-size: 13px; letter-spacing: .2em; text-transform: uppercase; }

.rs-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.rs-step {
  min-height: 160px; box-sizing: border-box; position: relative;
  padding: 55px 24px 24px;
  border: 1px solid #c89b6a44; border-radius: 20px;
  background: linear-gradient(150deg, #34121e, #1c0c13);
  box-shadow: inset 0 1px #ffffff11;
}
.rs-step::before { content: ""; position: absolute; left: 24px; right: 24px; top: 28px; height: 1px; background: linear-gradient(90deg, #a92a40, #c89b6a55); }
.rs-step::after {
  content: ""; position: absolute; top: 18px; left: 24px;
  width: 19px; height: 19px; border: 1px solid #e35a68; border-radius: 50%;
  background: #9e2035;
  box-shadow: 0 0 0 7px #8b1e2f40, 0 0 25px #c22a45;
  animation: rs-pulse 3s ease-in-out infinite;
}
.rs-step.done::after { background: var(--bronze-bright); border-color: #f0d49a; }
.rs-step h3 { margin: 0; color: #fff0eb; font-size: 18px; }
.rs-step p { margin: 8px 0 0; color: #cdb8b6; font-size: 14px; line-height: 1.55; }

.rs-rail { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.rs-card {
  height: 300px; position: relative; overflow: hidden; padding: 0;
  border: 1px solid #c89b6a70;
  border-radius: 150px 150px 22px 22px;
  background: #210e17;
  box-shadow: 0 18px 50px #090509aa, inset 0 1px #ffffff22;
  text-align: left; color: inherit; cursor: pointer;
  transition: border-color .2s ease, box-shadow .2s ease, filter .2s ease, transform .2s ease;
}
.rs-card:hover { border-color: #e3b77e; box-shadow: 0 24px 56px #8b1e2f66, inset 0 1px #ffffff22; filter: brightness(1.08); }
.rs-card:nth-child(2) { transform: translateY(18px); }
.rs-card img { width: 100%; height: 100%; -o-object-fit: cover; object-fit: cover; display: block; filter: brightness(.69) saturate(.75); }
.rs-card::before { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, #160910e8 0%, transparent 70%); }
.rs-card::after {
  content: ""; position: absolute; top: 28px; right: 25px;
  width: 48px; height: 48px; border: 1px solid #e1b77d; border-radius: 50%;
  background: #2a0f18a8;
  box-shadow: 0 0 0 6px #8b1e2f40, 0 0 24px #b42b43;
  backdrop-filter: blur(8px);
}
.rs-card-label { position: absolute; left: 26px; bottom: 25px; right: 22px; z-index: 1; }
.rs-card-label h3 { margin: 0; font-size: 22px; color: #fff1eb; }
.rs-card-label p { margin: 7px 0 0; color: #dfccca; font-size: 13px; line-height: 1.5; }
.rs-card[aria-pressed="true"] { border-color: var(--bronze-bright); box-shadow: 0 0 0 2px var(--bronze-bright), 0 24px 56px #8b1e2f66, inset 0 1px #ffffff22; }
.rs-card:disabled { cursor: not-allowed; opacity: .55; filter: brightness(.7); }

.rs-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.rs-field {
  min-height: 210px; padding: 26px; box-sizing: border-box;
  border: 1px solid #c89b6a55; border-radius: 20px;
  background: #170b12;
  box-shadow: inset 0 1px #ffffff11;
}
.rs-field-label { margin: 0 0 14px; color: #dfb27c; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }
.rs-input, .rs-textarea {
  box-sizing: border-box; width: 100%;
  border: 1px solid #c89b6a55; border-radius: 12px;
  background: #10090d; color: #fff1eb;
  padding: 13px 14px; font: 14px system-ui, -apple-system, sans-serif;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.rs-input:focus, .rs-textarea:focus { outline: 2px solid #c89b6a; outline-offset: 2px; }
.rs-textarea { min-height: 96px; resize: vertical; }
.rs-input::-moz-placeholder, .rs-textarea::-moz-placeholder { color: #8a6f6c; }
.rs-input::placeholder, .rs-textarea::placeholder { color: #8a6f6c; }
.rs-check { display: flex; align-items: flex-start; gap: 12px; margin-top: 12px; color: #e4d2d0; font-size: 14px; line-height: 1.55; cursor: pointer; }
.rs-check input { margin-top: 4px; accent-color: #a92640; width: 16px; height: 16px; }

.rs-upload {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px; min-height: 130px;
  border: 1px dashed #c89b6a77; border-radius: 16px;
  color: #cdb8b6; cursor: pointer; text-align: center; padding: 18px; font-size: 13px;
  transition: border-color .2s ease, background .2s ease;
}
.rs-upload:hover { border-color: var(--bronze-bright); background: #ffffff08; }

.rs-thumbs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.rs-thumb { position: relative; width: 84px; height: 84px; border-radius: 12px; overflow: hidden; border: 1px solid #c89b6a55; background: #10090d; box-shadow: 0 6px 18px #09050a88; }
.rs-thumb img, .rs-thumb video { width: 100%; height: 100%; -o-object-fit: cover; object-fit: cover; }
.rs-thumb button { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%; border: 1px solid #c89b6a55; background: #2a0f18cc; color: #fff; cursor: pointer; font-size: 13px; line-height: 1; }

.rs-approval {
  min-height: 300px; margin-top: 68px;
  border: 1px solid #8f53604d; border-radius: 26px;
  background: linear-gradient(135deg, #30111d, #170b12);
  display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 18px;
  box-shadow: 0 20px 56px #07040777, inset 0 1px #ffffff0c;
  position: relative; overflow: hidden; padding: 40px; text-align: center;
}
.rs-approval::before {
  content: ""; width: 120px; height: 120px; border-radius: 50%;
  border: 1px solid #e3b77e;
  box-shadow: 0 0 0 14px #8b1e2f22, 0 0 80px #c22a4544;
  animation: rs-glow 4s ease-in-out infinite;
}
.rs-approval::after { content: ""; position: absolute; inset: 22px; border: 1px solid #c89b6a26; border-radius: 20px; pointer-events: none; }
.rs-approval h2 { position: relative; margin: 0; font-size: 26px; color: #fff1eb; z-index: 1; }
.rs-approval p { position: relative; margin: 0; font-size: 14px; color: #cdb8b6; max-width: 56ch; z-index: 1; line-height: 1.6; }
.rs-approval .rs-cta { position: relative; z-index: 1; }

.rs-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 30px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; border: 1px solid #c89b6a45; }
.rs-badge.pendente { color: #e1b881; background: #2a0f18; }
.rs-badge.aprovado { color: #fff4ed; background: linear-gradient(135deg, #a5263b, #c44453); border-color: transparent; }
.rs-badge.reprovado { color: #ff9d9d; background: #8b1e2f22; border-color: #8b1e2f55; }
.rs-badge.suspenso { color: #cdb8b6; background: #2a0f18; }

.rs-gate { max-width: 560px; margin: 120px auto; text-align: center; }
.rs-gate h1 { font-size: 30px; color: #fff1eb; margin: 0 0 14px; }
.rs-gate p { color: #cdb8b6; line-height: 1.6; }

.rs-footer { min-height: 100px; margin-top: 66px; border-top: 1px solid #c89b6a44; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.rs-footline { width: 170px; height: 2px; background: linear-gradient(90deg, #c89b6a, transparent); }

@keyframes rs-bloom { 0% { opacity: 0; filter: brightness(.72); } 100% { opacity: 1; filter: brightness(1); } }
@keyframes rs-rise { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes rs-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes rs-pulse { 0%, 100% { box-shadow: 0 0 0 6px #8b1e2f36, 0 0 16px #b52a42; } 50% { box-shadow: 0 0 0 10px #8b1e2f50, 0 0 30px #e8445f; } }
@keyframes rs-glow { 0%, 100% { box-shadow: 0 0 0 14px #8b1e2f22, 0 0 80px #c22a4533; } 50% { box-shadow: 0 0 0 20px #8b1e2f33, 0 0 110px #c22a4555; } }

@media (max-width: 1023px) {
  .rs-page { padding: 24px 20px 80px; }
  .rs-hero { height: auto; aspect-ratio: 4 / 5; }
  .rs-hero-art { display: none; }
  .rs-hero-content { left: 18px; right: 18px; bottom: 24px; width: auto; padding: 20px; }
  .rs-section { padding: 22px; }
  .rs-rail, .rs-steps { grid-template-columns: 1fr; }
  .rs-fields { grid-template-columns: 1fr; }
  .rs-card { height: 240px; border-radius: 120px 120px 22px 22px; }
  .rs-card:nth-child(2) { transform: none; }
  .rs-approval { min-height: 240px; }
}
@media (max-width: 520px) {
  .rs-card { height: 200px; border-radius: 90px 90px 18px 18px; }
  .rs-hero-title { font-size: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  .rs-page, .rs-top, .rs-hero, .rs-section, .rs-hero-art, .rs-step::after, .rs-dot, .rs-approval::before { animation: none !important; }
}

/* Tema visual aplicado pelo admin: troca as cores fixas pelos tokens do tema. */
.rs-page[data-scoped-theme] {
  background:
    radial-gradient(1000px 560px at 52% 0%, hsl(var(--primary) / 0.18), transparent 72%),
    hsl(var(--background)) !important;
  color: hsl(var(--foreground)) !important;
  animation: none !important;
}
.rs-page[data-scoped-theme] .rs-top { border-bottom-color: hsl(var(--gold) / 0.4); }
.rs-page[data-scoped-theme] .rs-hero-title { color: hsl(var(--foreground)); }
.rs-page[data-scoped-theme] .rs-hero-sub { color: hsl(var(--muted-foreground)); }
.rs-page[data-scoped-theme] .rs-eyebrow { color: hsl(var(--gold)); }
.rs-page[data-scoped-theme] .rs-ornament { border-color: hsl(var(--gold) / 0.5); }.rsh-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.rsh-tab { min-height: 44px; padding: 0 16px; border-radius: 30px; border: 1px solid #c89b6a40; background: #1c0c13; color: #dfb27c; font-size: 13px; cursor: pointer; transition: all .2s; }
.rsh-tab[aria-pressed="true"] { background: linear-gradient(135deg, #8b1e2f, #b52a42); color: #fff4ed; border-color: transparent; box-shadow: 0 8px 22px #8b1e2f66; }
.rsh-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.rsh-card { position: relative; border-radius: 18px; overflow: hidden; border: 1px solid #c89b6a33; background: #170a10; box-shadow: 0 18px 40px -24px #000; transition: transform .25s, border-color .25s; }
.rsh-card:hover { transform: translateY(-4px); border-color: #c89b6a88; }
.rsh-card .rs-thumb { aspect-ratio: 3 / 4; width: 100%; height: auto; border-radius: 0; }
.rsh-card .rs-thumb :is(img, video) { width: 100%; height: 100%; -o-object-fit: cover; object-fit: cover; }
.rsh-body { padding: 12px 14px 14px; display: grid; gap: 6px; }
.rsh-body h3 { font-size: 15px; font-weight: 600; color: #f5e9e6; margin: 0; }
.rsh-body p { font-size: 12px; color: #cdb8b6; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rsh-chip { position: absolute; top: 10px; left: 10px; z-index: 1; padding: 3px 9px; border-radius: 30px; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; background: #0d0a0ccc; color: #dfb27c; border: 1px solid #c89b6a55; }
.rsh-live { left: auto; right: 10px; color: #ff8a9b; border-color: #ff5d7366; }
.rsh-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.rsh-btn { display: inline-flex; align-items: center; gap: 5px; height: 32px; padding: 0 12px; border-radius: 30px; border: 1px solid #c89b6a55; background: #2a0f18; color: #f5e9e6; font-size: 12px; cursor: pointer; text-decoration: none; }
.rsh-btn:hover { background: #491523; }
.rsh-btn.on { background: linear-gradient(135deg, #b52a42, #d25d64); border-color: transparent; }
.rsh-btn.match { background: linear-gradient(135deg, #c89b6a, #e3b77e); color: #1b0c12; border-color: transparent; font-weight: 600; }
.rsh-panel { border: 1px solid #c89b6a33; border-radius: 20px; padding: 22px; background: radial-gradient(500px 180px at 0% 0%, #8b1e2f33, transparent 70%), #140a0f; }
.rsh-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.rsh-input { flex: 1; min-width: 220px; height: 40px; padding: 0 14px; border-radius: 12px; border: 1px solid #c89b6a44; background: #0d0a0c; color: #f5e9e6; font-size: 13px; }
.rsh-rail { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; }
.rsh-live-item { flex: none; width: 220px; text-decoration: none; color: inherit; }
.rsh-empty { color: #cdb8b6; font-size: 14px; padding: 18px 0; }
.rsh-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin-bottom: 22px; }
.rsh-stat { border: 1px solid #c89b6a33; border-radius: 16px; padding: 14px; background: #170a10; }
.rsh-stat b { display: block; font-size: 24px; color: #e3b77e; }
.rsh-stat span { font-size: 12px; color: #cdb8b6; }
@media (max-width: 640px) { .rsh-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }