/* /static/styles/home.css */

/* ---------- Theme ---------- */
:root {
  --cryptrr-nav: #0f172a;
  --cryptrr-bg: #f8fafc;
}

html {
  overflow-x: hidden;
}

body {
  background: var(--cryptrr-bg);
  overflow-x: hidden;
  padding-right: 0 !important;
}

/* ---------- Keep main page scrollbar visible ---------- */
body.modal-open,
body.idv-overlay-open {
  padding-right: 0 !important;
  overflow-y: auto !important;
}

.modal-open .navbar,
.modal-open .seller-subnav-wrap,
.modal-open .seller-home-page {
  padding-right: 0 !important;
}

/* ---------- Prevent Bootstrap modal from adding its own scrollbar ---------- */
.modal {
  overflow-x: hidden !important;
  overflow-y: auto !important;
  padding-right: 0 !important;
}

.modal-open .modal {
  padding-right: 0 !important;
}

.modal-dialog {
  margin-top: 1.75rem;
  margin-bottom: 1.75rem;
}

/* ---------- Search input ---------- */
.cryptrr-search:focus {
  box-shadow: none;
  border-color: #2563eb;
  outline: none;
}

/* ---------- Hamburger ---------- */
.menu-btn {
  border: none;
  background: transparent;
  padding: 8px;
  border-radius: 10px;
  transition: background 0.15s ease, transform 0.05s ease;
}

.menu-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.menu-btn:active {
  transform: scale(0.96);
  background: rgba(255, 255, 255, 0.12);
}

/* ---------- Right-side buttons ---------- */
.sell-btn {
  background: #2563eb;
  color: #fff;
  border: none;
  padding: 10px 18px;
  font-weight: 600;
  border-radius: 12px;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.sell-btn:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
}

.sell-btn:active {
  transform: translateY(0);
  background: #1e40af;
}

/* ---------- Login/Account button ---------- */
.login-btn {
  background: transparent;
  color: #e5e7eb;
  border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 10px 16px;
  font-weight: 500;
  border-radius: 12px;
  transition: all 0.15s ease;
  white-space: nowrap;

  --bs-btn-color: #e5e7eb;
  --bs-btn-bg: transparent;
  --bs-btn-border-color: rgba(255, 255, 255, 0.22);
  --bs-btn-hover-color: #fff;
  --bs-btn-hover-bg: rgba(255, 255, 255, 0.08);
  --bs-btn-hover-border-color: rgba(255, 255, 255, 0.38);
  --bs-btn-active-color: #fff;
  --bs-btn-active-bg: rgba(255, 255, 255, 0.08);
  --bs-btn-active-border-color: rgba(255, 255, 255, 0.38);
  --bs-btn-focus-shadow-rgb: 0, 0, 0;
}

.login-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.38);
  color: #fff;
}

.login-btn:active {
  background: rgba(255, 255, 255, 0.12);
}

.login-btn:focus,
.login-btn:focus-visible {
  box-shadow: none !important;
  outline: none !important;
}

.dropdown .login-btn.show {
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: rgba(255, 255, 255, 0.38) !important;
  color: #fff !important;
}

/* ---------- Verify banner ---------- */
.verify-banner {
  background: linear-gradient(135deg, #0ea75a, #16a34a);
  color: #ffffff;
  border-radius: 16px;
  padding: 14px 16px;
  box-shadow: 0 10px 24px rgba(22, 163, 74, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.18);

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;

  transform: translateY(-14px);
  opacity: 0;
  max-height: 0;
  overflow: hidden;

  transition:
    transform 380ms cubic-bezier(0.2, 0.9, 0.2, 1),
    opacity 220ms ease,
    max-height 420ms cubic-bezier(0.2, 0.9, 0.2, 1),
    padding 420ms cubic-bezier(0.2, 0.9, 0.2, 1);
}

.verify-banner.show {
  transform: translateY(0);
  opacity: 1;
  max-height: 140px;
}

.verify-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.25);
  flex: 0 0 auto;
}

.verify-icon i {
  font-size: 1.35rem;
}

.verify-title {
  font-weight: 900;
  font-size: 1.05rem;
}

.verify-subtitle {
  opacity: 0.95;
  font-size: 0.92rem;
}

.verify-close {
  border: none;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  transition: background 0.15s ease, transform 0.05s ease;
}

.verify-close:hover {
  background: rgba(255, 255, 255, 0.26);
}

.verify-close:active {
  transform: scale(0.97);
}

/* ---------- Navbar layout (desktop) ---------- */
.cryptrr-nav-layout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
}

.cryptrr-left {
  order: 1;
}

.cryptrr-center {
  order: 2;
  flex: 1 1 auto;
  display: flex;
  justify-content: center;
  min-width: 0;
}

.cryptrr-right {
  order: 3;
}

/* ---------- Logo ---------- */
.cryptrr-logo {
  height: 95px;
  width: auto;
}

/* ---------- Desktop input sizing ---------- */
@media (min-width: 626px) {
  .cryptrr-search-wrap .form-control {
    height: 48px;
    font-size: 1rem;
  }

  .cryptrr-search-wrap .btn {
    height: 48px;
    display: flex;
    align-items: center;
  }
}

/* ---------- Mobile layout adjustments ---------- */
@media (max-width: 625px) {
  .navbar .container-fluid {
    padding-top: 4px;
    padding-bottom: 12px;
  }

  .cryptrr-nav-layout {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "left right"
      "center center";
    gap: 14px 12px;
    align-items: center;
  }

  .cryptrr-left {
    grid-area: left;
  }

  .cryptrr-right {
    grid-area: right;
    justify-self: end;
  }

  .cryptrr-center {
    grid-area: center;
    width: 100%;
    justify-content: stretch;
    padding-bottom: 4px;
  }

  .cryptrr-center .cryptrr-search-wrap {
    max-width: none !important;
  }

  .cryptrr-logo {
    height: 60px;
  }
}

/* ---------- Ultra-small phones ---------- */
@media (max-width: 380px) {
  .sell-btn {
    padding: 9px 12px;
  }

  .login-btn {
    padding: 9px 12px;
  }
}

/* ---------- Overlay filter panel ---------- */
.cryptrr-search-wrap {
  position: relative;
}

#filtersOverlay {
  position: absolute;
  left: 0;
  top: calc(100% + 10px);
  width: 100%;
  z-index: 1050;
  display: none;
}

#filtersOverlay .card {
  border-radius: 16px;
  overflow: hidden;
}

.advanced-title {
  font-weight: 800;
  font-size: 1.1rem;
}

/* ---------- ID verification loading overlay ---------- */
.idv-loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(15, 23, 42, 0.55);
  display: none;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(2px);
  overflow: hidden;
}

.idv-loading-overlay.show {
  display: flex;
}

.idv-loading-card {
  background: #0b1220;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 18px;
  min-width: 260px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}

.idv-loading-title {
  font-weight: 800;
  font-size: 1.05rem;
  margin-bottom: 6px;
}

.idv-loading-subtitle {
  opacity: 0.85;
  font-size: 0.92rem;
}

.idv-tip {
  color: rgba(255, 255, 255, 0.75);
}

/* ---------- Payment overlay ---------- */
.idv-pay-overlay {
  position: fixed;
  inset: 0;
  z-index: 2500;
  background: rgba(15, 23, 42, 0.55);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  backdrop-filter: blur(2px);
  overflow: hidden;
}

.idv-pay-overlay.show {
  display: flex;
}

.idv-pay-card {
  width: min(520px, 100%);
  background: #0b1220;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
  padding: 18px;
  max-height: none;
  overflow: visible;
}

@media (max-width: 625px) {
  .idv-pay-overlay {
    align-items: flex-start;
    padding: 12px;
  }

  .idv-pay-card {
    margin-top: 8px;
    margin-bottom: 12px;
    width: 100%;
  }
}

.idv-pay-title {
  font-weight: 900;
  font-size: 1.1rem;
  margin-bottom: 2px;
}

.idv-pay-sub {
  opacity: 0.85;
  font-size: 0.95rem;
  margin-bottom: 12px;
}

.idv-pay-box {
  position: relative;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  padding: 12px;
}

.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
    "Liberation Mono", "Courier New", monospace;
  font-size: 0.92rem;
  word-break: break-all;
}

.qr-wrap {
  width: 160px;
  height: 160px;
  border-radius: 14px;
  background: #ffffff;
  display: grid;
  place-items: center;
  overflow: hidden;
  flex: 0 0 auto;
}

.idv-pay-actions .btn {
  border-radius: 12px;
}

/* ---------- Processing overlay ---------- */
.idv-pay-processing-overlay {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(2px);
  border-radius: 14px;
}

.idv-pay-processing-overlay.show {
  display: flex;
}

.idv-pay-processing-card {
  width: min(420px, 100%);
  background: rgba(11, 18, 32, 0.96);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}

.idv-pay-processing-title {
  font-weight: 900;
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.idv-pay-processing-sub {
  opacity: 0.85;
  font-size: 0.92rem;
}

/* ---------- Footer logo ---------- */
.cryptrr-logo-footer {
  display: none;
}

@media (max-width: 625px) {
  .cryptrr-logo-nav {
    display: none;
  }

  .cryptrr-logo-footer {
    display: block;
  }
}