/* ============================================================
   DirectCom — Remote Support (ISL Online) module + modal
   Self-contained styles. Brand: navy/blue/green + orange accent.
   ============================================================ */

/* --- Prominent call-to-action band on the support page --- */
.rs-band {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg, 18px);
  background: linear-gradient(135deg, #0A1628 0%, #13294a 55%, #1A56A0 130%);
  color: #fff;
  padding: 40px 44px;
  display: flex;
  align-items: center;
  gap: 30px;
  box-shadow: 0 24px 60px rgba(10, 22, 40, 0.28);
}
.rs-band::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(420px 300px at 88% 18%, rgba(74, 155, 50, 0.20), transparent 62%),
    radial-gradient(360px 280px at 8% 96%, rgba(26, 86, 160, 0.30), transparent 60%);
  pointer-events: none;
}
.rs-band > * { position: relative; z-index: 1; }
.rs-band-ic {
  flex-shrink: 0;
  width: 66px;
  height: 66px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #1A56A0, #49A632);
  box-shadow: 0 10px 26px rgba(26, 86, 160, 0.45);
}
.rs-band-ic svg { width: 32px; height: 32px; stroke: #fff; fill: none; stroke-width: 2; }
.rs-band-txt { flex: 1; min-width: 0; }
.rs-band-txt h3 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.4px;
  margin-bottom: 6px;
}
.rs-band-txt p {
  font-size: 1.02rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.74);
  max-width: 52ch;
}
.rs-start {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-heading);
  font-size: 1.06rem;
  font-weight: 700;
  color: #0A1628;
  background: linear-gradient(135deg, #FF9A4D, #F47A1F);
  border: none;
  border-radius: 12px;
  padding: 16px 28px;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(244, 122, 31, 0.42);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  white-space: nowrap;
}
.rs-start:hover { transform: translateY(-2px); box-shadow: 0 16px 34px rgba(244, 122, 31, 0.55); }
.rs-start:active { transform: translateY(0); }
.rs-start svg { width: 20px; height: 20px; stroke: #0A1628; fill: none; stroke-width: 2.2; }

@media (max-width: 760px) {
  .rs-band { flex-direction: column; text-align: center; padding: 32px 24px; }
  .rs-band-txt p { margin-inline: auto; }
  .rs-start { width: 100%; justify-content: center; }
}

/* --- Floating remote-support button (always reachable) --- */
.rs-fab {
  position: fixed;
  bottom: 24px;
  inset-inline-end: 24px;
  z-index: 1100;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.96rem;
  color: #0A1628;
  background: linear-gradient(135deg, #FF9A4D, #F47A1F);
  border: none;
  border-radius: 999px;
  padding: 13px 20px;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(244, 122, 31, 0.45);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  animation: rsFabIn 0.5s 0.6s both cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes rsFabIn { from { opacity: 0; transform: translateY(16px) scale(0.9); } to { opacity: 1; transform: none; } }
.rs-fab:hover { transform: translateY(-2px); box-shadow: 0 16px 38px rgba(244, 122, 31, 0.58); }
.rs-fab:active { transform: translateY(0); }
.rs-fab svg { width: 21px; height: 21px; stroke: #0A1628; fill: none; stroke-width: 2; flex-shrink: 0; }
@media (max-width: 560px) {
  .rs-fab { padding: 14px; gap: 0; }
  .rs-fab .rs-fab-label { display: none; }
}
@media (prefers-reduced-motion: reduce) { .rs-fab { animation: none; transition: none; } }

/* --- Modal --- */
.rs-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.rs-modal.open { display: flex; }
.rs-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 16, 30, 0.74);
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
  animation: rsFade 0.25s ease;
}
@keyframes rsFade { from { opacity: 0; } to { opacity: 1; } }
.rs-dialog {
  position: relative;
  width: 100%;
  max-width: 460px;
  background: #fff;
  border-radius: 22px;
  box-shadow: 0 36px 90px rgba(0, 0, 0, 0.45);
  padding: 38px 34px 32px;
  text-align: center;
  animation: rsIn 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes rsIn { from { opacity: 0; transform: translateY(22px) scale(0.97); } to { opacity: 1; transform: none; } }
.rs-close {
  position: absolute;
  top: 14px;
  inset-inline-end: 14px;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: none;
  background: var(--warm-100, #f1efea);
  color: var(--text-sub, #5b6472);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background 0.2s ease, color 0.2s ease;
}
.rs-close:hover { background: #e7e3db; color: var(--navy, #0A1628); }
.rs-close svg { width: 18px; height: 18px; stroke: currentColor; stroke-width: 2.4; fill: none; }

.rs-badge {
  width: 58px;
  height: 58px;
  margin: 0 auto 16px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #1A56A0, #49A632);
  box-shadow: 0 12px 26px rgba(26, 86, 160, 0.32);
}
.rs-badge svg { width: 28px; height: 28px; stroke: #fff; fill: none; stroke-width: 2; }
.rs-title {
  font-family: var(--font-heading);
  font-size: 1.42rem;
  font-weight: 800;
  color: var(--navy, #0A1628);
  letter-spacing: -0.3px;
  margin-bottom: 6px;
}
.rs-lead { font-size: 0.98rem; color: var(--text-sub, #5b6472); line-height: 1.6; margin-bottom: 22px; }

/* state switching */
.rs-state { display: none; }
.rs-state.active { display: block; }

/* loading */
.rs-spinner {
  width: 46px;
  height: 46px;
  margin: 26px auto;
  border: 4px solid var(--warm-100, #eee);
  border-top-color: var(--blue, #1A56A0);
  border-radius: 50%;
  animation: rsSpin 0.85s linear infinite;
}
@keyframes rsSpin { to { transform: rotate(360deg); } }

/* code */
.rs-code-label { font-size: 0.84rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--blue, #1A56A0); margin-bottom: 10px; }
.rs-code {
  font-family: var(--font-data, monospace);
  font-size: clamp(2.2rem, 8vw, 2.9rem);
  font-weight: 800;
  letter-spacing: 0.16em;
  color: var(--navy, #0A1628);
  background: var(--warm-100, #f5f4f1);
  border: 1.5px dashed rgba(26, 86, 160, 0.4);
  border-radius: 14px;
  padding: 16px 12px;
  direction: ltr;
  unicode-bidi: isolate;
}
.rs-copy {
  margin: 10px auto 0;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-sub, #5b6472);
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 8px;
  transition: color 0.2s ease, background 0.2s ease;
}
.rs-copy:hover { color: var(--blue, #1A56A0); background: rgba(26, 86, 160, 0.07); }
.rs-copy svg { width: 15px; height: 15px; stroke: currentColor; fill: none; stroke-width: 2; }

/* code-entry input */
.rs-form { margin-top: 4px; }
.rs-form .rs-code-label { display: block; text-align: start; margin-bottom: 9px; }
.rs-input {
  width: 100%;
  font-family: var(--font-data, monospace);
  font-size: clamp(1.7rem, 6vw, 2.3rem);
  font-weight: 800;
  letter-spacing: 0.14em;
  text-align: center;
  color: var(--navy, #0A1628);
  background: var(--warm-100, #f5f4f1);
  border: 1.5px dashed rgba(26, 86, 160, 0.4);
  border-radius: 14px;
  padding: 16px 12px;
  direction: ltr;
  unicode-bidi: isolate;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.rs-input::placeholder { color: rgba(10, 22, 40, 0.22); letter-spacing: 0.1em; }
.rs-input:focus { border-style: solid; border-color: var(--blue, #1A56A0); background: #fff; box-shadow: 0 0 0 4px rgba(26, 86, 160, 0.12); }
.rs-act--primary:disabled { opacity: 0.5; cursor: not-allowed; box-shadow: none; transform: none; }

.rs-actions { display: grid; gap: 11px; margin-top: 22px; }
.rs-act {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.02rem;
  border-radius: 12px;
  padding: 15px 20px;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}
.rs-act svg { width: 19px; height: 19px; fill: none; stroke-width: 2.1; }
.rs-act--primary {
  color: #fff;
  background: linear-gradient(135deg, #1A56A0, #2D6A1F);
  border: none;
  box-shadow: 0 10px 24px rgba(26, 86, 160, 0.34);
}
.rs-act--primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(26, 86, 160, 0.46); }
.rs-act--primary svg { stroke: #fff; }
.rs-act--ghost {
  color: var(--navy, #0A1628);
  background: var(--white, #fff);
  border: 1.5px solid rgba(10, 22, 40, 0.14);
}
.rs-act--ghost:hover { border-color: var(--blue, #1A56A0); color: var(--blue, #1A56A0); transform: translateY(-1px); }
.rs-act--ghost svg { stroke: currentColor; }

.rs-hint { margin-top: 16px; font-size: 0.9rem; line-height: 1.55; color: var(--text-sub, #5b6472); }
.rs-hint b { color: var(--navy, #0A1628); font-weight: 700; }

.rs-secure {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  color: var(--green, #2D6A1F);
  font-weight: 600;
}
.rs-secure svg { width: 15px; height: 15px; stroke: var(--green, #2D6A1F); fill: none; stroke-width: 2; }

/* error */
.rs-err-ic { width: 52px; height: 52px; margin: 8px auto 14px; border-radius: 50%; display: grid; place-items: center; background: rgba(214, 69, 69, 0.12); }
.rs-err-ic svg { width: 26px; height: 26px; stroke: #d64545; fill: none; stroke-width: 2.2; }
.rs-err-msg { font-size: 1rem; color: var(--text-main, #1f2733); line-height: 1.6; margin-bottom: 8px; }
.rs-err-phone { font-family: var(--font-data); font-size: 1.3rem; font-weight: 800; color: var(--navy, #0A1628); direction: ltr; display: inline-block; margin: 4px 0 18px; }

/* demo ribbon (preview only) */
.rs-demo-tag {
  display: none;
  margin: -10px auto 16px;
  width: max-content;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #b25a00;
  background: rgba(244, 122, 31, 0.14);
  border: 1px solid rgba(244, 122, 31, 0.3);
  border-radius: 999px;
  padding: 4px 12px;
}
.rs-modal[data-demo="1"] .rs-demo-tag { display: block; }

@media (prefers-reduced-motion: reduce) {
  .rs-dialog, .rs-backdrop, .rs-spinner { animation: none !important; }
  .rs-spinner { border-top-color: var(--blue); }
}
