@font-face {
    font-family: Satoshi;
    src: url("Satoshi-Variable-ChAXbpFa.ttf") format("truetype");
    font-display: swap
}

:root {
    line-height: 1.5;
    font-weight: 500;
    color-scheme: light dark;
    color: #fff;
    background-color: #242424;
    font-synthesis: none;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    --bg-clr-1: #010101;
    --bg-clr-2: #111111;
    --accent-1: #6B5FF6;
    --border-clr-1: #8B8B8B;
    --border-clr-2: #515151;
    --txt-clr-1: #D6D6D6
}

body {
    margin: 0;
    display: flex;
    place-items: center;
    min-width: 320px;
    min-height: 100vh;
    background-color: var(--bg-clr-1);
    font-family: Satoshi !important
}

body * {
    font-family: inherit
}

*,
*:after,
*:before {
    box-sizing: border-box;
}

body [selectable=true] {
    user-select: all !important;
    -moz-user-select: all !important;
    -ms-user-select: all !important;
    -webkit-user-select: all !important
}

#application-root, #app-container, #portfolio-root, #policy-application, #terms-application {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center
}

/* Scroll animation base */
.reveal {
    opacity: 0;
    transform: translateY(60px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* Visible state */
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Animation variants */

.reveal-left {
    transform: translateX(-60px);
}

.reveal-right {
    transform: translateX(60px);
}

.reveal.active.reveal-left,
.reveal.active.reveal-right {
    transform: translateX(0);
}

#primary-content, #main-interface, #main-content, #content-area {
    width: 100%;
    min-height: 100vh;
    position: relative
}

#mobile-interface {
    display: none;
    width: 100%;
}

#mobile-content {
    width: 100%;
    min-height: 100vh;
    position: relative;
    color: #aab0c4;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    .brand-logo-element {
        height: 100px;

        img {
            height: 100%;
        }
    }

    span {
        font-size: 18px;
    }
}

.chat-widget {
    font-family: Inter, Arial, sans-serif;
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 9999;
    display: flex;
    align-items: flex-end;
}

.chat-toggle {
    width: 64px;
    height: 64px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    box-shadow: 0 18px 40px rgba(37, 99, 235, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    color: white;
}

.chat-toggle:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 22px 48px rgba(37, 99, 235, 0.42);
}

.chat-toggle:active {
    transform: scale(0.97);
}

.chat-box {
    position: absolute;
    right: 0;
    bottom: calc(100% + 14px);

    width: 360px;
    height: 520px;
    border-radius: 24px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(14px);
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.7);

    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(20px) scale(0.92);
    transform-origin: bottom right;
    transition:
        opacity 0.28s ease,
        transform 0.28s ease,
        visibility 0.28s ease;

    display: flex;
    flex-direction: column;
}

.chat-widget.open .chat-box {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0) scale(1);
}

.chat-header {
    background: linear-gradient(135deg, #2563eb, #1e40af);
    color: white;
    padding: 18px 18px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.support-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    display: grid;
    place-items: center;
    font-weight: 700;
    font-size: 15px;
    border: 1px solid rgba(255,255,255,0.2);
    flex-shrink: 0;
}

.support-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 2px;
}

.support-status {
    font-size: 13px;
    opacity: 0.9;
    display: flex;
    align-items: center;
    gap: 6px;
}

.support-status::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4ade80;
    box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.18);
}

.chat-close {
    border: none;
    background: rgba(255, 255, 255, 0.14);
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 12px;
    cursor: pointer;
    font-size: 18px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.chat-close:hover {
    background: rgba(255, 255, 255, 0.22);
    transform: rotate(90deg);
}

.chat-messages {
    flex: 1;
    padding: 18px;
    overflow-y: auto;
    background:
    linear-gradient(to bottom, rgba(239,246,255,0.9), rgba(255,255,255,0.96));
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.message-row {
    display: flex;
}

.message-row.support {
    justify-content: flex-start;
}

.message-row.user {
    justify-content: flex-end;
}

.message {
    max-width: 82%;
    padding: 12px 14px;
    border-radius: 18px;
    line-height: 1.45;
    font-size: 14px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
    animation: fadeInUp 0.25s ease;
    white-space: pre-wrap;
    word-break: break-word;
}

.message.support {
    background: white;
    color: #0f172a;
    border-top-left-radius: 6px;
}

.message.user {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: white;
    border-top-right-radius: 6px;
}

.chat-footer {
    padding: 14px;
    background: rgba(255, 255, 255, 0.95);
    border-top: 1px solid rgba(37, 99, 235, 0.08);
}

.chat-form {
    display: flex;
    gap: 10px;
    align-items: center;
}

.chat-input {
    flex: 1;
    border: 1px solid #dbeafe;
    background: #f8fbff;
    border-radius: 16px;
    padding: 14px 16px;
    outline: none;
    font-size: 14px;
    color: #0f172a;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.chat-input:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.16);
}

.send-btn {
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    color: white;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    display: grid;
    place-items: center;
    flex-shrink: 0;
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.send-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(37, 99, 235, 0.32);
}

.send-btn:active {
    transform: scale(0.96);
}

.chat-hint {
    margin-top: 10px;
    text-align: center;
    font-size: 12px;
    color: #64748b;
}

@keyframes fadeInUp {
    from {
    opacity: 0;
    transform: translateY(8px);
    }
    to {
    opacity: 1;
    transform: translateY(0);
    }
}

/* @media (max-width: 520px) {
    .chat-widget {
    right: 14px;
    bottom: 14px;
    left: 14px;
    align-items: stretch;
    }

    .chat-box {
    width: 100%;
    height: min(72vh, 520px);
    }

    .chat-toggle {
    align-self: flex-end;
    }
} */

@media (max-width: 768px) {
    .chat-widget {
        right: 12px;
        bottom: 12px;
        gap: 10px;
    }

    .chat-toggle {
        width: 56px;
        height: 56px;
    }

    .chat-box {
        width: min( calc(100vw - 24px), 360px );
        height: min(70vh, 520px);
        border-radius: 18px;
    }
}

.message-row.message-new .message {
  animation: messagePopIn 0.28s ease;
}

@keyframes messagePopIn {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(0.96);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.quick-replies {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
  min-width: 0;
  max-width: 100%;
  padding: 0 2px 6px;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x proximity;
  scroll-padding-inline: 2px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(37, 99, 235, 0.38) transparent;
}

.quick-replies::-webkit-scrollbar {
  height: 6px;
}

.quick-replies::-webkit-scrollbar-track {
  background: transparent;
}

.quick-replies::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.38);
}

.quick-reply {
  display: flex;
  flex: 0 0 max-content;
  align-items: center;
  justify-content: center;
  width: max-content;
  min-width: max-content;
  max-width: none;
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid rgba(37, 99, 235, 0.28);
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  box-sizing: border-box;
  font: inherit;
  font-size: 12px;
  line-height: 1.25;
  text-align: center;
  white-space: nowrap;
  overflow-wrap: normal;
  scroll-snap-align: start;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.quick-reply:hover,
.quick-reply:focus-visible {
  border-color: #2563eb;
  background: #dbeafe;
  outline: none;
  transform: translateY(-1px);
}

.quick-reply.operator-request {
  border-color: #2563eb;
  background: #2563eb;
  color: #fff;
}

.quick-reply:disabled {
  opacity: 0.6;
  cursor: wait;
  transform: none;
}

.operator-contact {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding: 10px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 14px;
  background: linear-gradient(135deg, #eff6ff, #f8fbff);
}

.operator-contact-copy {
  display: flex;
  flex: 1;
  min-width: 0;
  flex-direction: column;
  gap: 2px;
  color: #0f172a;
  font-size: 11px;
  line-height: 1.25;
}

.operator-contact-copy strong {
  color: #1d4ed8;
  font-size: 12px;
}

.operator-contact-button {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 8px 12px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.operator-contact-button:hover,
.operator-contact-button:focus-visible {
  outline: none;
  transform: translateY(-1px);
  box-shadow: 0 11px 22px rgba(37, 99, 235, 0.3);
}

.operator-contact-button:disabled {
  opacity: 0.6;
  cursor: wait;
  transform: none;
}

body.support-email-dialog-open {
  overflow: hidden;
}

.support-email-overlay[hidden] {
  display: none;
}

.support-email-overlay {
  position: fixed;
  inset: 0;
  z-index: 20000;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(2, 6, 23, 0.72);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.support-email-dialog {
  position: relative;
  width: min(420px, calc(100vw - 32px));
  padding: 28px;
  border: 1px solid rgba(96, 165, 250, 0.3);
  border-radius: 24px;
  background: #fff;
  color: #0f172a;
  text-align: center;
  box-shadow: 0 28px 80px rgba(2, 6, 23, 0.42);
}

.support-email-dialog h2 {
  margin: 12px 0 8px;
  color: #0f172a;
  font-size: 24px;
}

.support-email-dialog p {
  margin: 0 auto 16px;
  max-width: 320px;
  color: #475569;
  font-size: 14px;
  line-height: 1.5;
}

.support-email-icon {
  display: grid;
  width: 52px;
  height: 52px;
  margin: 0 auto;
  place-items: center;
  border-radius: 16px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  font-size: 26px;
  font-weight: 800;
  box-shadow: 0 12px 24px rgba(37, 99, 235, 0.25);
}

.support-email-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 10px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 20px;
  cursor: pointer;
}

.support-email-address {
  display: block;
  margin-bottom: 18px;
  padding: 12px 14px;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  background: #eff6ff;
  color: #1d4ed8 !important;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none !important;
  overflow-wrap: anywhere;
}

.support-email-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.support-email-open,
.support-email-copy {
  display: flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 12px;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none !important;
}

.support-email-open {
  border: 1px solid #2563eb;
  background: #2563eb;
  color: #fff !important;
}

.support-email-copy {
  border: 1px solid #bfdbfe;
  background: #fff;
  color: #1d4ed8;
}

@media (max-width: 420px) {
  .operator-contact {
    align-items: stretch;
    flex-direction: column;
  }

  .operator-contact-button {
    width: 100%;
  }

  .support-email-dialog {
    padding: 24px 18px 20px;
    border-radius: 20px;
  }

  .support-email-actions {
    grid-template-columns: 1fr;
  }
}
