/* ═══════════════ Fortochka — User Styles ═══════════════ */
/* Constructivist + Nostromo — Lissitzky cream theme */

/* ═══════════════ AUTH PAGE (split-screen) ═══════════════ */
.auth-wrapper {
  min-height: 100vh;
  display: flex;
  position: relative;
  z-index: 1;
}
.auth-split {
  display: flex;
  width: 100%;
  min-height: 100vh;
}
.auth-left {
  flex: 0 0 55%;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 3rem;
}
.auth-right {
  flex: 1;
  background: var(--bg-dark);
  padding: 3rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-left: 3px solid var(--accent);
}
.auth-right h2 {
  font-family: 'Russo One', sans-serif;
  font-size: 1rem;
  letter-spacing: 0.18em;
  color: #f0e8d8;
  margin-bottom: 2rem;
  text-transform: uppercase;
}
.auth-right .label { color: #9a958a; }
.auth-right .input {
  color: #f0e8d8;
  border-bottom-color: rgba(240, 232, 216, 0.12);
}
.auth-right .input:focus { border-bottom-color: var(--accent); }
.auth-right .input::placeholder { color: #6b6860; }
.auth-right .error-msg { color: #e02222; }
.auth-right .hint-text { color: #6b6860; }
.auth-right .lang-switch { color: #f0e8d8; }
.auth-footer {
  margin-top: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Lissitzky geometric elements */
.geo-circle {
  position: absolute;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: var(--accent);
  top: -40px;
  left: -40px;
}
.geo-square-b {
  position: absolute;
  width: 65px;
  height: 65px;
  background: var(--bg-dark);
  bottom: 55px;
  right: 70px;
  transform: rotate(18deg);
}
.geo-square-r {
  position: absolute;
  width: 50px;
  height: 50px;
  background: var(--accent);
  bottom: 40px;
  right: 100px;
  transform: rotate(18deg);
}
.geo-line1 {
  position: absolute;
  width: 350px;
  height: 1px;
  background: var(--bg-dark);
  top: 30%;
  left: -30px;
  transform: rotate(-22deg);
  opacity: 0.2;
}
.geo-line2 {
  position: absolute;
  width: 180px;
  height: 1px;
  background: var(--accent);
  top: 35%;
  left: 40px;
  transform: rotate(-22deg);
  opacity: 0.4;
}
.geo-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}
.auth-brand-title {
  font-family: 'Russo One', sans-serif;
  font-size: 3rem;
  letter-spacing: 0.3em;
  color: var(--text);
  position: relative;
  z-index: 1;
}
.auth-brand-tagline {
  font-family: 'PT Sans', sans-serif;
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  position: relative;
  z-index: 1;
}
.auth-link {
  color: var(--accent);
  text-decoration: none;
  cursor: pointer;
  font-weight: 700;
}
.auth-link:hover { text-decoration: underline; }
.auth-sub-text {
  color: #9a958a;
  font-size: 0.85rem;
  margin-top: 1.5rem;
}
.auth-field { margin-bottom: 1.5rem; }

/* ═══════════════ LOGO (constructivist) ═══════════════ */
.logo-block .logo-pane {
  fill: #f0e8d8;
}
.logo-pane {
  fill: var(--accent);
}
.logo-pane-tr {
  animation: pane-darken 5s linear 1s infinite;
}
@keyframes pane-darken {
  0%  { opacity: 0; }
  5%  { opacity: 0.75; }
  50% { opacity: 0.75; }
  60% { opacity: 0; }
  100% { opacity: 0; }
}
.logo-airplane {
  opacity: 0;
  animation: airplane-fly 5s linear 1s infinite;
}
@keyframes airplane-fly {
  0%  { opacity: 0; transform: translate(-6px, 5px); }
  5%  { opacity: 1; transform: translate(0, 0); }
  40% { opacity: 1; transform: translate(12px, -9px); }
  60% { opacity: 0; transform: translate(28px, -21px); }
  100% { opacity: 0; transform: translate(-6px, 5px); }
}
.logo-trail {
  stroke: #f0e8d8;
  stroke-width: 1.5;
  stroke-linecap: round;
  opacity: 0;
  animation: trail-fade 5s linear 1s infinite;
}
.logo-trail-1 { animation-delay: 1.2s; }
.logo-trail-2 { animation-delay: 1.35s; }
@keyframes trail-fade {
  0%, 8%  { opacity: 0; }
  18% { opacity: 0.5; }
  30% { opacity: 0.3; }
  45% { opacity: 0; }
  100% { opacity: 0; }
}

/* ═══════════════ DEPLOY HERO (empty state CTA) ═══════════════ */
.deploy-hero {
  background: var(--bg-dark);
  color: #f0e8d8;
  padding: 2rem 2.5rem;
  position: relative;
  overflow: hidden;
  margin-bottom: 1rem;
  border-left: 3px solid var(--accent);
}
.deploy-hero-geo {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.deploy-hero-circle {
  position: absolute;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.9;
  right: 60px;
  top: 50%;
  transform: translateY(-50%);
}
.deploy-hero-sq1 {
  position: absolute;
  width: 45px;
  height: 45px;
  background: #f0e8d8;
  opacity: 0.12;
  right: 220px;
  top: 25px;
  transform: rotate(18deg);
}
.deploy-hero-sq2 {
  position: absolute;
  width: 30px;
  height: 30px;
  background: var(--accent);
  opacity: 0.4;
  right: 240px;
  top: 10px;
  transform: rotate(18deg);
}
.deploy-hero-line1 {
  position: absolute;
  width: 300px;
  height: 1px;
  background: #f0e8d8;
  opacity: 0.08;
  top: 70%;
  left: -20px;
  transform: rotate(-8deg);
}
.deploy-hero-line2 {
  position: absolute;
  width: 150px;
  height: 1px;
  background: var(--accent);
  opacity: 0.3;
  top: 75%;
  left: 30px;
  transform: rotate(-8deg);
}
.deploy-hero-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  right: 210px;
  bottom: 25px;
}
.deploy-hero-content {
  position: relative;
  z-index: 1;
}
.deploy-hero-title {
  font-family: 'Russo One', sans-serif;
  font-size: 1.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.3;
  margin: 0 0 0.75rem 0;
  max-width: 500px;
}
.deploy-hero-sub {
  font-family: 'PT Sans', sans-serif;
  font-size: 0.95rem;
  color: #c4b89e;
  margin: 0;
}

@media (max-width: 1023px) {
  .deploy-hero { padding: 2rem 1.5rem; }
  .deploy-hero-title { font-size: 1.3rem; }
  .deploy-hero-circle { width: 90px; height: 90px; right: 20px; }
  .deploy-hero-sq1 { display: none; }
  .deploy-hero-sq2 { display: none; }
  .deploy-hero-dot { display: none; }
}

/* ═══════════════ NODE CARDS ═══════════════ */
.node-card {
  border: 1px solid var(--border);
  border-radius: 2px;
  margin-bottom: 1rem;
  overflow: hidden;
  transition: border-color 0.2s;
}
.node-card:hover {
  border-color: var(--border-hover);
}
.node-header {
  padding: 0.7rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg-dark);
  color: #f0e8d8;
}
.node-header h3 {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
  font-weight: 500;
  margin: 0;
  color: #f0e8d8;
}
.node-body {
  padding: 1.5rem;
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  border-left: 3px solid var(--accent);
  background: var(--bg);
}
.node-col { flex: 1; min-width: 220px; }
.node-col h4 {
  font-family: 'Russo One', sans-serif;
  font-size: 0.6rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.7rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid var(--border);
}
.config-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.4rem 0;
  font-size: 0.85rem;
  color: var(--text);
}
.copy-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 0.15rem 0.5rem;
  font-size: 0.6rem;
  cursor: pointer;
  font-family: 'Russo One', sans-serif;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: all 0.15s;
}
.copy-btn:hover { border-color: var(--accent); color: var(--accent); }

.stat {
  font-family: 'JetBrains Mono', monospace;
  color: var(--text);
  font-weight: 600;
  font-size: 0.9rem;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: 'Russo One', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
}

/* ═══════════════ COIN CARDS ═══════════════ */
.coin-card {
  border: 1px solid var(--border);
  border-radius: 2px;
  padding: 0.75rem 0.5rem;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
  background: rgba(240, 232, 216, 0.3);
}
.coin-card:hover {
  border-color: var(--text-muted);
}
.coin-card.selected {
  border-color: var(--accent);
  background: var(--red-bg);
}
.coin-card .coin-symbol {
  font-family: 'Russo One', sans-serif;
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 0.1rem;
}
.coin-card.selected .coin-symbol { color: var(--accent); }
.coin-card .coin-name {
  font-size: 0.7rem;
  color: var(--text-dim);
}

/* ═══════════════ MISC COMPONENTS ═══════════════ */
.config-block {
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 2px;
  padding: 14px;
  margin-bottom: 12px;
}
.preset-btn {
  padding: 0.4rem 1rem;
  border: 1px solid var(--border);
  border-radius: 0;
  font-size: 0.8rem;
  cursor: pointer;
  background: transparent;
  color: var(--text-muted);
  font-family: 'Russo One', sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: all 0.15s;
}
.preset-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.preset-btn.active {
  border-color: var(--accent);
  color: var(--accent);
}
.back-link {
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s;
  font-size: 0.9rem;
  border: none;
  background: none;
  padding: 0;
}
.back-link:hover {
  color: var(--accent);
}
.accent-link {
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.2s;
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'PT Sans', sans-serif;
  font-weight: 700;
}
.accent-link:hover {
  opacity: 0.8;
}
.flag {
  font-size: 1.1rem;
  margin-right: 0.3rem;
  vertical-align: middle;
}
@keyframes pulse-success {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.05); }
}
.success-pulse {
  animation: pulse-success 0.6s ease-in-out 3;
}

/* ═══════════════ VOUCHER CARDS ═══════════════ */
.voucher-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}
.voucher-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 2px;
  padding: 1.25rem;
  transition: border-color 0.2s;
}
.voucher-card:hover {
  border-color: var(--border-hover);
  border-left-color: var(--accent);
}

/* ═══════════════ QR FULLSCREEN ═══════════════ */
.qr-fullscreen {
  position: fixed;
  inset: 0;
  background: rgba(46, 44, 40, 0.95);
  z-index: 200;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.qr-fullscreen img {
  max-width: min(80vw, 350px);
  width: 100%;
  border-radius: 2px;
}
.qr-fullscreen .qr-code-text {
  color: #f0e8d8;
  font-family: 'Russo One', sans-serif;
  font-size: 1rem;
  letter-spacing: 0.1em;
  margin-top: 1.5rem;
}
.qr-fullscreen .qr-amount-text {
  color: rgba(240, 232, 216, 0.6);
  font-size: 1rem;
  margin-top: 0.5rem;
}
.qr-fullscreen .qr-dismiss {
  color: rgba(240, 232, 216, 0.3);
  font-size: 0.8rem;
  margin-top: 2rem;
}

/* ═══════════════ TRAFFIC BARS ═══════════════ */
.traffic-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 0;
}
.traffic-label {
  width: 80px;
  font-size: 0.85rem;
  color: var(--text-muted);
  flex-shrink: 0;
}
.traffic-bar {
  flex: 1;
  height: 6px;
  background: var(--code-bg);
  border-radius: 0;
  overflow: hidden;
}
.traffic-fill {
  height: 100%;
  background: var(--accent);
  transition: width 0.6s ease;
}
.traffic-value {
  width: 80px;
  text-align: right;
  font-size: 0.85rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  flex-shrink: 0;
}

/* ═══════════════ PLATFORM TABS ═══════════════ */
.platform-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.platform-tab {
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 0;
  cursor: pointer;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-family: 'Russo One', sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: all 0.15s;
}
.platform-tab:hover {
  border-color: var(--accent);
  color: var(--text);
}
.platform-tab.active {
  border-color: var(--accent);
  background: var(--red-bg);
  color: var(--accent);
}

/* ═══════════════ TOGGLE SWITCH ═══════════════ */
.toggle-switch {
  position: relative;
  width: 44px;
  height: 24px;
  background: var(--text-dim);
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.3s;
  border: none;
  padding: 0;
}
.toggle-switch::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: #f0e8d8;
  border-radius: 50%;
  transition: transform 0.3s;
}
.toggle-switch.on {
  background: var(--accent);
}
.toggle-switch.on::after {
  transform: translateX(20px);
}

/* ═══════════════ HELP LAYOUT (3-column) ═══════════════ */
.help-layout {
  display: flex;
  gap: 0;
  border: 1px solid var(--border);
  flex: 1;
}
.help-platforms {
  flex: 0 0 200px;
  border-right: 1px solid var(--border);
  overflow-y: auto;
}
.help-guide {
  flex: 1;
  overflow-y: auto;
}
.help-faq {
  flex: 0 0 340px;
  overflow-y: auto;
}

@media (max-width: 1023px) {
  .help-layout {
    flex-direction: column;
    height: auto !important;
  }
  .help-platforms {
    flex: none !important;
    border-right: none;
    border-bottom: 1px solid var(--border);
    display: flex;
    overflow-x: auto;
  }
  .help-platforms > div:first-child {
    display: none; /* hide header on mobile, tabs are self-explanatory */
  }
  .help-platform-item {
    white-space: nowrap;
    border-bottom: none !important;
    border-left: none !important;
    border-right: 1px solid var(--border);
    padding: 0.6rem 1rem !important;
  }
  .help-platform-item.selected {
    background: var(--row-hover) !important;
    border-bottom: 3px solid var(--accent) !important;
    border-left: none !important;
  }
  .help-guide {
    border-right: none !important;
  }
  .help-faq {
    flex: none !important;
    border-top: 1px solid var(--border);
  }
}

/* ═══════════════ CONTACT / TICKETS ═══════════════ */
.contact-section {
  margin-top: 1.5rem;
}
.ticket-list-item {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  margin-bottom: 0.5rem;
  cursor: pointer;
  transition: background 0.15s;
}
.ticket-list-item:hover {
  background: var(--row-hover);
}
.ticket-messages {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.ticket-bubble {
  padding: 0.75rem 1rem;
  background: var(--code-bg);
  max-width: 85%;
}
.ticket-bubble.admin {
  border-left: 3px solid var(--accent);
  align-self: flex-start;
}
.bubble-sender {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}
.bubble-time {
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
}
.bubble-body {
  font-size: 0.85rem;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}

/* ═══════════════ WALLET LAYOUT ═══════════════ */
.wallet-columns {
  display: flex;
  gap: 1.5rem;
  align-items: stretch;
}
.wallet-left {
  flex: 1;
  min-width: 300px;
}
.wallet-right {
  flex: 0 0 320px;
  min-width: 280px;
}

/* ═══════════════ REGION PICKER ═══════════════ */
.region-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 0.75rem;
}
.region-card {
  border: 1px solid var(--border);
  border-left: 3px solid transparent;
  border-radius: 0;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.15s;
  background: rgba(240, 232, 216, 0.3);
}
.region-card:hover {
  border-left-color: var(--accent);
  background: rgba(240, 232, 216, 0.6);
}
.region-card.selected {
  border-left-color: var(--accent);
  background: var(--red-bg);
}
.region-card .country {
  font-family: 'Russo One', sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.region-card .city {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.1rem;
}
.region-card .price {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  color: var(--text);
  font-weight: 600;
  margin-top: 0.5rem;
}

/* ═══════════════ MOBILE BOTTOM NAV ═══════════════ */
.bottom-nav {
  display: none;
}

/* ═══════════════ DEPLOY MASTER-DETAIL ═══════════════ */
.deploy-master-detail {
  min-height: 350px;
  flex: 1;
}

/* When showing deploy flow on desktop, make content fill viewport exactly */
@media (min-width: 1024px) {
  .main-area.no-scroll {
    overflow: hidden;
  }
  .main-area.no-scroll .content-area {
    height: calc(100vh - 52px);
    overflow: hidden;
    padding-bottom: 0;
  }
  .main-area.no-scroll .content-area .page-enter {
    height: 100%;
    display: flex;
    flex-direction: column;
  }
}

@media (max-width: 1023px) {
  .deploy-master-detail {
    flex-direction: column !important;
    height: auto !important;
    min-height: 0 !important;
  }
  .deploy-master-detail .deploy-master {
    flex: none !important;
    max-height: none !important;
    overflow-y: visible !important;
    border-right: none !important;
    border-bottom: 1px solid var(--border);
  }
  .deploy-master-detail .deploy-detail {
    border-right: none !important;
    overflow-y: visible !important;
  }
  /* Features column on mobile: no scroll, no fixed height */
  .deploy-master-detail > div:last-child {
    flex: none !important;
    overflow-y: visible !important;
    width: 100% !important;
  }
  .wallet-columns {
    flex-direction: column;
  }
  .wallet-left,
  .wallet-right {
    flex: none !important;
    width: 100%;
    min-width: 0;
  }
  .deploy-hero {
    padding: 1.5rem !important;
  }
  .deploy-hero-title {
    font-size: 1.2rem !important;
  }
  .auth-split {
    flex-direction: column;
  }
  .auth-left {
    flex: none;
    min-height: 30vh;
    padding: 2rem;
  }
  .auth-right {
    flex: 1;
    padding: 2rem;
  }
  .geo-circle { width: 80px; height: 80px; top: -15px; left: -15px; }
  .geo-square-b { width: 30px; height: 30px; bottom: 15px; right: 25px; }
  .geo-square-r { width: 22px; height: 22px; bottom: 8px; right: 42px; }
  .geo-line1, .geo-line2 { display: none; }
  .geo-dot { display: none; }
  .auth-brand-title { font-size: 1.8rem; letter-spacing: 0.15em; }
  .auth-brand-tagline { font-size: 0.9rem; }
  .auth-left { min-height: 25vh; padding: 1.5rem; justify-content: flex-end; }
  .auth-right { padding: 2rem 1.5rem; }

  .bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(240, 232, 216, 0.95);
    backdrop-filter: blur(8px);
    border-top: 1px solid var(--border);
    justify-content: space-around;
    z-index: 50;
    padding: 0.4rem 0;
  }
  .bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.4rem 0.5rem;
    font-family: 'Russo One', sans-serif;
    font-size: 0.55rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.15s;
  }
  .bottom-nav-item.active { color: var(--accent); }
  .bottom-nav-item svg { width: 20px; height: 20px; margin-bottom: 2px; }

  .content-area {
    padding-bottom: 4.5rem;
  }
  .voucher-grid {
    grid-template-columns: 1fr;
  }
  .platform-tabs {
    gap: 0.25rem;
  }
  .metric-value {
    font-size: 1.6rem;
  }
  .node-body {
    flex-direction: column;
    gap: 1rem;
  }
  .region-grid {
    grid-template-columns: 1fr 1fr;
  }
}

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