/* ZeroPlain — WhatsApp-style 1:1 messenger. Original NexaTools design, no WhatsApp assets. */
:root {
  --wa-bg: #0b141a;
  --wa-panel: #111b21;
  --wa-panel-2: #202c33;
  --wa-panel-3: #2a3942;
  --wa-line: #222d34;
  --wa-line-2: #2f3b43;
  --wa-text: #e9edef;
  --wa-muted: #8696a0;
  --wa-soft: #aebac1;
  --wa-green: #00a884;
  --wa-green-dark: #005c4b;
  --wa-blue: #53bdeb;
  --wa-red: #f15c6d;
  --wa-radius: 8px;
}

[hidden] {
  display: none !important;
}

body.nc-in-chat .site-footer,
body.nc-in-chat .related-tools-section,
body.nc-in-chat #nc-about {
  display: none !important;
}

.nc-main {
  display: block !important;
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1180px !important;
  margin: 0 auto;
  padding: 16px 16px 48px !important;
}

body.nc-in-chat .nc-main {
  padding: 10px 16px 10px !important;
}

/* ---------------------------------------------------------------- welcome */

.nc-welcome {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  align-items: center;
  gap: clamp(24px, 5vw, 64px);
  max-width: 1000px;
  margin: 8px auto 34px;
}

.nc-welcome-art {
  position: relative;
  display: flex;
  justify-content: center;
  padding: 12px 0;
}

.nc-preview {
  width: min(300px, 100%);
  margin: 0 auto;
  padding: 9px;
  border: 1px solid var(--wa-line-2);
  border-radius: 22px;
  background: #0b141a;
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.42);
  position: relative;
}

.nc-preview-screen {
  overflow: hidden;
  border-radius: 14px;
  background: var(--wa-bg);
}

.nc-preview-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: var(--wa-panel-2);
}

.nc-preview-head .wa-avatar {
  width: 27px;
  height: 27px;
  font-size: 11px;
}

.nc-preview-id {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.nc-preview-name {
  color: var(--wa-text);
  font-size: 11.5px;
  font-weight: 600;
}

.nc-preview-state {
  color: var(--wa-muted);
  font-size: 8.5px;
}

.nc-preview-lock {
  margin-left: auto;
  width: 14px;
  height: 14px;
  color: var(--wa-muted);
}

.nc-preview-body {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-height: 224px;
  padding: 15px 10px 16px;
  background-color: var(--wa-bg);
  background-image: radial-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 16px 16px;
}

.nc-preview-day {
  align-self: center;
  margin-bottom: 3px;
  padding: 3px 8px;
  border-radius: 5px;
  background: #182229;
  color: var(--wa-muted);
  font-size: 8px;
  text-transform: uppercase;
}

.nc-preview-bubble {
  max-width: 82%;
  padding: 6px 8px 5px;
  border-radius: 7px;
  color: var(--wa-text);
  font-size: 10.5px;
  line-height: 15px;
  position: relative;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.18);
}

.nc-preview-bubble.in {
  align-self: flex-start;
  border-top-left-radius: 0;
  background: var(--wa-panel-2);
}

.nc-preview-bubble.out {
  align-self: flex-end;
  border-top-right-radius: 0;
  background: var(--wa-green-dark);
}

.nc-preview-bubble small {
  display: block;
  margin-top: 2px;
  color: rgba(233, 237, 239, 0.6);
  font-size: 7.5px;
  text-align: right;
}

.nc-preview-foot {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  background: var(--wa-panel-2);
}

.nc-preview-input {
  flex: 1;
  height: 27px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 14px;
  background: var(--wa-panel-3);
  color: var(--wa-muted);
  font-size: 8.5px;
}

.nc-preview-send {
  width: 27px;
  height: 27px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--wa-green);
  color: #0b141a;
}

.nc-preview-send svg {
  width: 13px;
  height: 13px;
}

.nc-preview-e2e {
  position: absolute;
  right: -12px;
  bottom: 34px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 10px;
  border: 1px solid var(--wa-line-2);
  border-radius: 8px;
  background: #111b21;
  color: var(--wa-muted);
  font-size: 9.5px;
  font-weight: 500;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4);
}

.nc-preview-e2e svg {
  width: 11px;
  height: 11px;
  color: var(--wa-green);
}

.nc-welcome-copy {
  max-width: 440px;
  width: 100%;
}

.nc-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary, #fafafa);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.nc-brand-mark {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  background: var(--wa-green);
  color: #0b141a;
  font-size: 15px;
  font-weight: 800;
}

.nc-welcome-copy h1 {
  margin: 18px 0 10px;
  color: var(--text-primary, #fafafa);
  font-size: clamp(2rem, 4.4vw, 2.85rem);
  line-height: 1.07;
  letter-spacing: -0.035em;
}

.nc-lede {
  margin: 0 0 22px;
  color: var(--text-secondary, #a1a1aa);
  font-size: 14.5px;
  line-height: 1.65;
}

.nc-join-card {
  padding: 18px;
  border: 1px solid var(--border-subtle, #27272a);
  border-radius: 12px;
  background: var(--wa-panel);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.22);
}

.nc-join-form {
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.nc-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.nc-field label {
  color: var(--wa-muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.nc-field small {
  color: #667781;
  font-size: 11px;
  line-height: 1.45;
}

.nc-input {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 44px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: var(--wa-radius);
  background: var(--wa-panel-2);
  transition: border-color 0.15s ease;
}

.nc-input:focus-within {
  border-color: var(--wa-green);
}

.nc-input span {
  color: var(--wa-muted);
  font-size: 14px;
}

.nc-input input {
  width: 100%;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--wa-text);
  font-family: inherit;
  font-size: 14px;
}

/*
 * The shared site stylesheet paints every focused form field with a blue
 * border and its own background. Neutralise that inside ZeroPlain so the
 * surrounding wrappers own the focus treatment.
 */
.nc-input input,
.wa-search input,
.wa-input,
.wa-dialog-input {
  outline: 0 !important;
  box-shadow: none !important;
  -webkit-appearance: none;
}

.nc-input input,
.wa-input {
  border: 0 !important;
  background: transparent !important;
}

.wa-search input {
  border: 0 !important;
  background: var(--wa-panel-3) !important;
}

.wa-search input:focus {
  border-color: transparent !important;
  box-shadow: none !important;
}

.wa-dialog-input {
  border: 1px solid transparent !important;
  background: var(--wa-panel-2) !important;
}

.wa-dialog-input:focus {
  border-color: var(--wa-green) !important;
  box-shadow: none !important;
}

.nc-input input::placeholder {
  color: #667781;
}

.nc-join-button {
  width: 100%;
  height: 44px;
  border: 0;
  border-radius: var(--wa-radius);
  background: var(--wa-green);
  color: #0b141a;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.nc-join-button:hover {
  background: #06cf9c;
}

.nc-join-button:active {
  transform: translateY(1px);
}

.nc-join-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.nc-join-error {
  margin: 0;
  color: var(--wa-red);
  font-size: 12px;
  line-height: 1.45;
}

.nc-fineprint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin: 2px 0 0;
  color: #667781;
  font-size: 10.5px;
}

.nc-fineprint svg {
  width: 11px;
  height: 11px;
}

.nc-points {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 16px;
  margin: 15px 0 0;
  padding: 0;
  list-style: none;
  color: var(--text-secondary, #a1a1aa);
  font-size: 11.5px;
}

.nc-points li::before {
  content: '✓';
  margin-right: 5px;
  color: var(--wa-green);
  font-weight: 700;
}


/* ------------------------------------------------------------------- app */

.nc-app {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  width: 100%;
  height: clamp(500px, calc(100vh - 90px), 820px);
  max-width: 1180px;
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid var(--wa-line);
  border-radius: 12px;
  background: var(--wa-panel);
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.28);
  color: var(--wa-text);
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

/* The app is dark in both site themes. */
.nc-app *,
.nc-app *::before,
.nc-app *::after {
  box-sizing: border-box;
}

.wa-sidebar {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  border-right: 1px solid var(--wa-line);
  background: var(--wa-panel);
}

.wa-side-head {
  display: flex;
  align-items: center;
  gap: 9px;
  flex: 0 0 60px;
  padding: 0 12px;
  background: var(--wa-panel-2);
}

.wa-avatar {
  position: relative;
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--wa-panel-3);
  color: var(--wa-text);
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  user-select: none;
}

.wa-avatar.wa-avatar-self {
  background: #00a884;
  color: #0b141a;
}

.wa-avatar::after {
  content: '';
  position: absolute;
  right: -1px;
  bottom: -1px;
  width: 10px;
  height: 10px;
  border: 2px solid var(--wa-panel-2);
  border-radius: 50%;
  background: transparent;
  opacity: 0;
}

.wa-avatar[data-online='true']::after {
  opacity: 1;
  background: var(--wa-green);
}

.wa-side-id {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}

.wa-side-id strong {
  overflow: hidden;
  color: var(--wa-text);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wa-conn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  overflow: hidden;
  color: var(--wa-muted);
  font-size: 11px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wa-conn::before {
  content: '';
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--wa-muted);
}

.wa-conn[data-tone='online']::before {
  background: var(--wa-green);
}

.wa-conn[data-tone='pending']::before {
  background: #f0b429;
}

.wa-conn[data-tone='error']::before {
  background: var(--wa-red);
}

.wa-icon {
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--wa-soft);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.wa-icon:hover {
  background: var(--wa-panel-3);
  color: var(--wa-text);
}

.wa-icon:focus-visible,
.wa-chat-item:focus-visible,
.wa-send:focus-visible,
.wa-menu button:focus-visible {
  outline: 2px solid var(--wa-green);
  outline-offset: -2px;
}

.wa-icon svg {
  width: 20px;
  height: 20px;
}

#nc-list-close {
  display: none;
}

.wa-search {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  padding: 8px 12px;
  border-bottom: 1px solid var(--wa-line);
  background: var(--wa-panel);
}

.wa-search > svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  color: var(--wa-muted);
}

.wa-search input {
  flex: 1;
  min-width: 0;
  height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: var(--wa-radius);
  outline: 0;
  background: var(--wa-panel-3);
  color: var(--wa-text);
  font-family: inherit;
  font-size: 12.5px;
}

.wa-search input::placeholder {
  color: var(--wa-muted);
}

.wa-search input:focus {
  box-shadow: 0 0 0 1px var(--wa-green);
}

.wa-search-go {
  height: 36px;
  padding: 0 11px;
  border: 0;
  border-radius: var(--wa-radius);
  background: var(--wa-panel-2);
  color: var(--wa-text);
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
}

.wa-search-go:hover {
  background: #31444d;
}

.wa-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex: 0 0 auto;
  padding: 13px 15px 6px;
  color: var(--wa-muted);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

#nc-archived-toggle {
  border: 0;
  background: transparent;
  color: var(--wa-green);
  font-family: inherit;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
  cursor: pointer;
  text-transform: none;
}

.wa-chat-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #374248 transparent;
}

.wa-chat-list::-webkit-scrollbar,
.wa-messages::-webkit-scrollbar {
  width: 6px;
}

.wa-chat-list::-webkit-scrollbar-thumb,
.wa-messages::-webkit-scrollbar-thumb {
  border-radius: 6px;
  background: #374248;
}

.wa-chat-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 70px;
  padding: 0 11px 0 14px;
  border-bottom: 1px solid #1c272d;
  cursor: pointer;
  transition: background 0.12s ease;
}

.wa-chat-item:hover {
  background: #202c33;
}

.wa-chat-item.active {
  background: #2a3942;
}

.wa-chat-item .wa-avatar {
  width: 48px;
  height: 48px;
  font-size: 16px;
}

.wa-chat-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 0;
}

.wa-chat-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

.wa-chat-name {
  overflow: hidden;
  color: var(--wa-text);
  font-size: 14.5px;
  font-weight: 500;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wa-chat-time {
  flex: 0 0 auto;
  color: var(--wa-muted);
  font-size: 10.5px;
}

.wa-chat-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

.wa-chat-preview {
  overflow: hidden;
  color: var(--wa-muted);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wa-chat-preview svg {
  width: 13px;
  height: 13px;
  margin-right: 3px;
  vertical-align: -2px;
}

.wa-chat-badge {
  min-width: 18px;
  height: 18px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--wa-green);
  color: #0b141a;
  font-size: 10.5px;
  font-weight: 800;
}

.wa-chat-item.wa-muted .wa-chat-badge {
  background: var(--wa-muted);
}

.wa-chat-pin,
.wa-chat-mute {
  flex: 0 0 auto;
  width: 12px;
  height: 12px;
  color: var(--wa-muted);
}

.wa-chat-more {
  width: 24px;
  height: 26px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--wa-muted);
  cursor: pointer;
  opacity: 0;
}

.wa-chat-item:hover .wa-chat-more,
.wa-chat-more:focus-visible {
  opacity: 1;
}

.wa-chat-more:hover {
  background: #374248;
  color: var(--wa-text);
}

.wa-chat-more svg {
  width: 16px;
  height: 16px;
}

.wa-empty-list {
  padding: 28px 22px;
  color: var(--wa-muted);
  font-size: 12.5px;
  line-height: 1.65;
  text-align: center;
}

.wa-empty-list strong {
  display: block;
  margin-bottom: 5px;
  color: var(--wa-soft);
  font-size: 13px;
  font-weight: 500;
}

.wa-side-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex: 0 0 auto;
  padding: 9px 14px;
  border-top: 1px solid var(--wa-line);
  color: #667781;
  font-size: 10px;
}

.wa-side-foot span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.wa-side-foot svg {
  width: 10px;
  height: 10px;
}

/* ------------------------------------------------------------- chat pane */

.wa-chatpane {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  background: var(--wa-bg);
}

.wa-chat-head {
  position: relative;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 9px;
  flex: 0 0 60px;
  padding: 0 10px 0 14px;
  border-bottom: 1px solid var(--wa-line);
  background: var(--wa-panel-2);
}

.wa-chat-head .wa-avatar {
  width: 40px;
  height: 40px;
}

.wa-peer {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1;
  min-width: 0;
}

.wa-peer strong {
  overflow: hidden;
  color: var(--wa-text);
  font-size: 14.5px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wa-peer-status,
.wa-typing {
  overflow: hidden;
  color: var(--wa-muted);
  font-size: 11.5px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wa-peer-status[data-tone='online'] {
  color: var(--wa-green);
}

.wa-typing {
  color: var(--wa-green);
}

.wa-typing:not([hidden]) + .wa-peer-status {
  display: none;
}

#nc-back {
  display: none;
  margin-left: -6px;
}

#nc-plus {
  margin-left: 2px;
}

/* Floating menus ---------------------------------------------------------- */

.wa-pop {
  position: fixed;
  z-index: 80;
  min-width: 196px;
  padding: 5px 0;
  border: 1px solid var(--wa-line-2);
  border-radius: 8px;
  background: #233138;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.48);
}

#nc-plus-menu {
  position: absolute;
  top: 54px;
  right: 10px;
  z-index: 30;
}

.wa-pop button {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  min-height: 36px;
  padding: 8px 14px;
  border: 0;
  background: transparent;
  color: var(--wa-text);
  font-family: inherit;
  font-size: 12.5px;
  text-align: left;
  cursor: pointer;
}

.wa-pop button:hover {
  background: #2a3942;
}

.wa-pop button svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  color: var(--wa-muted);
}

.wa-pop .wa-danger {
  color: #f19a9a;
}

.wa-pop hr {
  margin: 4px 0;
  border: 0;
  border-top: 1px solid var(--wa-line-2);
}

/* Toast ------------------------------------------------------------------- */

.wa-toast {
  position: absolute;
  top: 70px;
  left: 50%;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: calc(100% - 28px);
  padding: 8px 10px 8px 12px;
  border: 1px solid var(--wa-line-2);
  border-radius: 8px;
  background: #233138;
  color: var(--wa-text);
  font-size: 12px;
  line-height: 1.4;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.42);
  transform: translateX(-50%);
}

.wa-toast-action {
  flex: 0 0 auto;
  padding: 4px 8px;
  border: 0;
  border-radius: 5px;
  background: var(--wa-green);
  color: #0b141a;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.wa-toast-close {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--wa-muted);
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
}

.wa-toast-close:hover {
  background: #2a3942;
  color: var(--wa-text);
}


/* --------------------------------------------------------------- messages */

.wa-messages {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 16px 6% 12px;
  background-color: var(--wa-bg);
  background-image: radial-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: 22px 22px;
  scrollbar-width: thin;
  scrollbar-color: #374248 transparent;
}

.wa-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  max-width: 390px;
  margin: auto;
  padding: 24px;
  text-align: center;
}

.wa-empty-icon {
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  border: 2px solid #2a3942;
  border-radius: 50%;
  color: var(--wa-muted);
}

.wa-empty-icon svg {
  width: 28px;
  height: 28px;
}

.wa-empty strong {
  margin-bottom: 7px;
  color: var(--wa-text);
  font-size: 19px;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.wa-empty p {
  margin: 0;
  color: var(--wa-muted);
  font-size: 12.5px;
  line-height: 1.6;
}

.wa-empty .wa-empty-lock {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 16px;
  color: #667781;
  font-size: 10.5px;
}

.wa-empty-lock svg {
  width: 11px;
  height: 11px;
}

.wa-day {
  align-self: center;
  margin: 10px 0 8px;
  padding: 5px 11px;
  border-radius: 6px;
  background: #182229;
  color: var(--wa-muted);
  font-size: 10.5px;
  font-weight: 500;
  line-height: 1.2;
  text-transform: uppercase;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.12);
}

.wa-row {
  display: flex;
  width: 100%;
  margin-top: 4px;
}

.wa-row.out {
  justify-content: flex-end;
}

.wa-row.wa-grouped {
  margin-top: 1px;
}

.wa-msg-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  max-width: min(66%, 520px);
}

.wa-row.out .wa-msg-wrap {
  align-items: flex-end;
}

.wa-bubble {
  position: relative;
  display: flow-root;
  max-width: 100%;
  padding: 6px 8px 6px 9px;
  border-radius: 7px;
  background: var(--wa-panel-2);
  color: var(--wa-text);
  font-size: 13.5px;
  line-height: 18.5px;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.16);
  overflow: visible;
  cursor: default;
}

.wa-row.wa-grouped .wa-bubble {
  border-top-left-radius: 7px;
  border-top-right-radius: 7px;
}

.wa-row.out .wa-bubble {
  border-top-right-radius: 0;
  background: var(--wa-green-dark);
}

.wa-row.in .wa-bubble {
  border-top-left-radius: 0;
}

.wa-row:not(.wa-grouped).out .wa-bubble::after {
  content: '';
  position: absolute;
  top: 0;
  right: -7px;
  width: 0;
  height: 0;
  border-top: 8px solid var(--wa-green-dark);
  border-right: 7px solid transparent;
}

.wa-row:not(.wa-grouped).in .wa-bubble::after {
  content: '';
  position: absolute;
  top: 0;
  left: -7px;
  width: 0;
  height: 0;
  border-top: 8px solid var(--wa-panel-2);
  border-left: 7px solid transparent;
}

.wa-bubble.wa-deleted {
  background: #1d282e;
}

.wa-row.out .wa-bubble.wa-deleted {
  background: #1d3b34;
}

.wa-bubble.wa-deleted .wa-text {
  color: var(--wa-muted);
  font-style: italic;
}

.wa-bubble.wa-deleted .wa-text::before {
  content: '🚫';
  margin-right: 6px;
  font-style: normal;
  filter: grayscale(1);
}

.wa-text {
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.wa-text a {
  color: var(--wa-blue);
  text-decoration: none;
  overflow-wrap: anywhere;
}

.wa-text a:hover {
  text-decoration: underline;
}

.wa-edited {
  color: rgba(233, 237, 239, 0.58);
  font-size: 9.5px;
  font-style: italic;
}

.wa-forwarded {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 3px;
  color: rgba(233, 237, 239, 0.62);
  font-size: 10.5px;
  font-style: italic;
  line-height: 1.3;
}

.wa-forwarded svg {
  width: 11px;
  height: 11px;
}

.wa-quote {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin: 1px 0 4px;
  padding: 3px 7px;
  border-left: 3px solid var(--wa-green);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.18);
  cursor: pointer;
}

.wa-row.in .wa-quote {
  border-left-color: #06cf9c;
}

.wa-quote-name {
  overflow: hidden;
  color: var(--wa-green);
  font-size: 10.5px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wa-row.out .wa-quote-name {
  color: #06cf9c;
}

.wa-quote-text {
  display: -webkit-box;
  overflow: hidden;
  color: rgba(233, 237, 239, 0.66);
  font-size: 11px;
  line-height: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.wa-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  float: right;
  margin: 3px 0 -2px 8px;
  color: rgba(233, 237, 239, 0.58);
  font-size: 10px;
  line-height: 14px;
  white-space: nowrap;
}

.wa-msg-time {
  font-size: 10px;
}

.wa-tick {
  display: inline-flex;
  align-items: center;
  color: #8696a0;
}

.wa-tick svg {
  width: 14px;
  height: 11px;
}

.wa-tick[data-status='read'] {
  color: var(--wa-blue);
}

.wa-star {
  width: 10px;
  height: 10px;
  color: #f0c75e;
}

.wa-reactions {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  margin-top: -2px;
  padding: 0 3px;
}

.wa-reaction {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  min-height: 22px;
  padding: 1px 6px;
  border: 1px solid var(--wa-line-2);
  border-radius: 11px;
  background: #233138;
  color: var(--wa-soft);
  font-size: 13px;
  line-height: 1;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.wa-reaction.wa-mine {
  border-color: #2c5f54;
  background: #1d3b34;
  color: #d5f5e9;
}

.wa-reaction b {
  font-size: 10px;
  font-weight: 600;
}

.wa-highlight {
  animation: wa-highlight 1.4s ease;
}

@keyframes wa-highlight {
  0%,
  100% {
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.16);
  }
  25%,
  75% {
    box-shadow: 0 0 0 3px rgba(0, 168, 132, 0.55);
  }
}

/* --------------------------------------------------------------- composer */

.wa-context {
  display: flex;
  align-items: center;
  gap: 9px;
  flex: 0 0 auto;
  padding: 7px 12px;
  border-top: 1px solid var(--wa-line);
  background: var(--wa-panel-2);
}

.wa-context-bar {
  width: 3px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 2px;
  background: var(--wa-green);
}

.wa-context-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}

.wa-context-label {
  color: var(--wa-green);
  font-size: 10.5px;
  font-weight: 600;
}

.wa-context-text {
  overflow: hidden;
  color: var(--wa-muted);
  font-size: 11.5px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.wa-context-close {
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--wa-muted);
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
}

.wa-context-close:hover {
  background: var(--wa-panel-3);
  color: var(--wa-text);
}

.wa-composer {
  position: relative;
  display: flex;
  align-items: flex-end;
  gap: 7px;
  flex: 0 0 auto;
  padding: 8px 11px;
  padding-bottom: max(8px, env(safe-area-inset-bottom));
  background: var(--wa-panel-2);
}

.wa-composer > .wa-icon {
  width: 38px;
  height: 42px;
  color: var(--wa-muted);
}

.wa-composer > .wa-icon:hover {
  background: transparent;
  color: var(--wa-soft);
}

.wa-input-wrap {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: flex-end;
  padding: 6px 10px;
  border-radius: var(--wa-radius);
  background: var(--wa-panel-3);
}

.wa-input-wrap:focus-within {
  box-shadow: 0 0 0 1px rgba(0, 168, 132, 0.55);
}

.wa-input {
  width: 100%;
  min-height: 26px;
  max-height: 118px;
  padding: 4px 0;
  border: 0;
  outline: 0;
  resize: none;
  background: transparent;
  color: var(--wa-text);
  font-family: inherit;
  font-size: 14px;
  line-height: 19px;
}

.wa-input::placeholder {
  color: var(--wa-muted);
}

.wa-send {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: var(--wa-green);
  color: #0b141a;
  cursor: pointer;
  transition: background 0.15s ease, opacity 0.15s ease;
}

.wa-send:hover {
  background: #06cf9c;
}

.wa-send:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.wa-send svg {
  width: 20px;
  height: 20px;
}

.wa-emoji-panel {
  position: absolute;
  left: 8px;
  bottom: calc(100% - 2px);
  z-index: 25;
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 1px;
  width: min(286px, calc(100vw - 32px));
  max-height: 216px;
  overflow-y: auto;
  padding: 7px;
  border: 1px solid var(--wa-line-2);
  border-radius: 10px;
  background: #233138;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.48);
}

.wa-emoji-panel button {
  width: 31px;
  height: 31px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 6px;
  background: transparent;
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
}

.wa-emoji-panel button:hover {
  background: var(--wa-panel-3);
}

/* Reactions picker and message menu --------------------------------------- */

.wa-react-picker {
  position: fixed;
  z-index: 85;
  display: flex;
  align-items: center;
  gap: 1px;
  padding: 4px 5px;
  border: 1px solid var(--wa-line-2);
  border-radius: 22px;
  background: #233138;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.5);
}

.wa-react-picker button {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.1s ease, background 0.1s ease;
}

.wa-react-picker button:hover {
  background: var(--wa-panel-3);
  transform: scale(1.18);
}

.wa-msg-menu {
  min-width: 174px;
}


/* ---------------------------------------------------------------- dialogs */

.nc-dialog,
.wa-dialog {
  width: min(440px, calc(100vw - 28px));
  max-width: 440px;
  padding: 0;
  border: 1px solid var(--wa-line-2);
  border-radius: 12px;
  background: #111b21;
  color: var(--wa-text);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.55);
}

.nc-dialog::backdrop,
.wa-dialog::backdrop {
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(2px);
}

.nc-dialog-head,
.wa-dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 0;
}

.nc-dialog-head h2,
.wa-dialog-head h2 {
  margin: 2px 0 0;
  color: var(--wa-text);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.nc-kicker {
  color: var(--wa-green);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.nc-dialog-close,
.wa-dialog-close {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--wa-muted);
  font-size: 21px;
  line-height: 1;
  cursor: pointer;
}

.nc-dialog-close:hover,
.wa-dialog-close:hover {
  background: var(--wa-panel-3);
  color: var(--wa-text);
}

.nc-dialog > p,
.wa-dialog-body {
  margin: 12px 18px 0;
  color: var(--wa-muted);
  font-size: 12.5px;
  line-height: 1.6;
}

.nc-dialog > p strong {
  color: var(--wa-soft);
  font-weight: 600;
}

.nc-safety-number {
  margin: 14px 18px;
  padding: 12px;
  overflow-x: auto;
  border: 1px solid var(--wa-line);
  border-radius: 8px;
  background: #0b141a;
  color: #d1d7db;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 12px;
  line-height: 1.8;
  letter-spacing: 0.02em;
  white-space: pre-wrap;
  word-break: break-word;
}

.nc-dialog-actions,
.wa-dialog-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 18px 16px;
}

.nc-btn,
.wa-btn {
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid transparent;
  border-radius: 6px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.nc-btn-ghost,
.wa-btn-ghost {
  border-color: var(--wa-line-2);
  background: transparent;
  color: var(--wa-soft);
}

.nc-btn-ghost:hover,
.wa-btn-ghost:hover {
  background: var(--wa-panel-3);
  color: var(--wa-text);
}

.nc-btn-primary,
.wa-btn-primary {
  background: var(--wa-green);
  color: #0b141a;
}

.nc-btn-primary:hover,
.wa-btn-primary:hover {
  background: #06cf9c;
}

.wa-dialog-body {
  margin: 14px 18px 0;
  padding: 0;
}

.wa-dialog-input {
  width: 100%;
  height: 40px;
  padding: 0 11px;
  border: 1px solid transparent;
  border-radius: 7px;
  outline: 0;
  background: var(--wa-panel-2);
  color: var(--wa-text);
  font-family: inherit;
  font-size: 13px;
}

.wa-dialog-input:focus {
  border-color: var(--wa-green);
}

.wa-dialog-input::placeholder {
  color: var(--wa-muted);
}

.wa-dialog-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 210px;
  margin-top: 10px;
  overflow-y: auto;
}

.wa-dialog-contact {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 7px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--wa-text);
  font-family: inherit;
  font-size: 12.5px;
  text-align: left;
  cursor: pointer;
}

.wa-dialog-contact:hover,
.wa-dialog-contact.selected {
  background: var(--wa-panel-2);
}

.wa-dialog-contact .wa-avatar {
  width: 32px;
  height: 32px;
  font-size: 12px;
}

.wa-dialog-empty {
  padding: 10px 2px;
  color: var(--wa-muted);
  font-size: 12px;
  line-height: 1.6;
}

/* --------------------------------------------------------------- toast */

#nc-toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 120;
  max-width: calc(100vw - 32px);
  padding: 9px 14px;
  border: 1px solid var(--wa-line-2);
  border-radius: 7px;
  background: #233138;
  color: var(--wa-text);
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  font-size: 12px;
  line-height: 1.4;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.42);
  transform: translateX(-50%);
}

#nc-toast[data-tone='error'] {
  border-color: rgba(241, 92, 109, 0.4);
  color: #ffd7dc;
}

/* ---------------------------------------------------------------- about */

#nc-about {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 34px;
  max-width: 1000px;
  margin: 36px auto 0;
  padding-top: 28px;
  border-top: 1px solid var(--border-subtle, #27272a);
}

.nc-about-intro h2 {
  margin: 0 0 9px;
  color: var(--text-primary, #fafafa);
  font-size: 19px;
  letter-spacing: -0.01em;
}

.nc-about-intro p {
  margin: 0 0 14px;
  color: var(--text-secondary, #a1a1aa);
  font-size: 12.5px;
  line-height: 1.65;
}

.nc-about-intro a {
  color: var(--wa-green);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}

.nc-about-list {
  display: flex;
  flex-direction: column;
}

.nc-about-list details {
  padding: 12px 0;
  border-bottom: 1px solid var(--border-subtle, #27272a);
}

.nc-about-list summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text-primary, #fafafa);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.nc-about-list summary::-webkit-details-marker {
  display: none;
}

.nc-about-list summary::after {
  content: '+';
  flex: 0 0 auto;
  color: var(--wa-muted);
  font-size: 17px;
  font-weight: 400;
}

.nc-about-list details[open] summary::after {
  content: '−';
}

.nc-about-list p {
  margin: 8px 0 0;
  color: var(--text-secondary, #a1a1aa);
  font-size: 12.5px;
  line-height: 1.65;
}

/* ------------------------------------------------------------ responsive */

@media (max-width: 1080px) {
  .nc-app {
    grid-template-columns: 320px minmax(0, 1fr);
  }
}

@media (max-width: 900px) {
  .nc-welcome {
    grid-template-columns: 1fr;
    max-width: 540px;
    gap: 0;
  }

  .nc-welcome-art {
    display: none;
  }

  .nc-welcome-copy {
    max-width: 100%;
  }

  .nc-app {
    grid-template-columns: 300px minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  body.nc-in-chat {
    height: 100dvh;
    overflow: hidden;
  }

  body.nc-in-chat .nc-main {
    padding: 6px !important;
  }

  /* The shared mobile form reset forces tall textareas and 16px text. Keep
     the chat composer compact while retaining the iOS-safe 16px font. */
  .wa-input {
    min-height: 26px !important;
    max-height: 118px !important;
    padding: 4px 0 !important;
    line-height: 20px;
  }

  body.nc-in-chat .nc-app {
    height: calc(100dvh - 76px);
    min-height: 420px;
    border-radius: 8px;
  }

  .nc-app {
    display: block;
    grid-template-columns: none;
    height: calc(100dvh - 84px);
    min-height: 420px;
    border-radius: 8px;
  }

  .wa-sidebar {
    display: none;
    width: 100%;
    height: 100%;
    border-right: 0;
  }

  .wa-chatpane {
    display: flex;
    width: 100%;
    height: 100%;
  }

  .nc-app.wa-list-open .wa-sidebar {
    display: flex;
  }

  .nc-app.wa-list-open .wa-chatpane {
    display: none;
  }

  #nc-back,
  #nc-list-close {
    display: inline-flex;
  }

  .wa-chat-more {
    opacity: 1;
  }

  .wa-messages {
    padding: 13px 10px 9px;
  }

  .wa-msg-wrap {
    max-width: 86%;
  }

  .wa-bubble {
    font-size: 14px;
    line-height: 19px;
  }

  .wa-chat-head {
    padding-left: 6px;
  }

  .wa-toast {
    top: 66px;
    max-width: calc(100% - 16px);
    font-size: 11.5px;
  }

  #nc-plus-menu {
    right: 6px;
  }

  .na-about {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  #nc-about {
    grid-template-columns: 1fr;
    gap: 18px;
    margin-top: 25px;
    padding-top: 20px;
  }
}

@media (max-width: 520px) {
  .nc-main {
    padding: 10px 10px 34px !important;
  }

  .nc-welcome {
    margin-top: 2px;
    margin-bottom: 24px;
  }

  .nc-welcome-copy h1 {
    font-size: 1.9rem;
  }

  .nc-lede {
    font-size: 13.5px;
  }

  .nc-join-card {
    padding: 14px;
  }

  .wa-search {
    padding: 7px 9px;
  }

  .wa-search-go {
    display: none;
  }

  .wa-side-head {
    padding: 0 8px;
  }

  .wa-chat-head {
    gap: 6px;
  }

  .wa-chat-head .wa-avatar {
    width: 36px;
    height: 36px;
    font-size: 13px;
  }

  .wa-composer {
    gap: 4px;
    padding: 6px 7px;
    padding-bottom: max(6px, env(safe-area-inset-bottom));
  }

  .wa-composer > .wa-icon {
    width: 34px;
  }

  .wa-send {
    width: 40px;
    height: 40px;
  }

  .wa-empty {
    padding: 18px;
  }

  .wa-empty strong {
    font-size: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .wa-highlight {
    animation: none;
  }

  .wa-reaction,
  .wa-icon,
  .wa-send {
    transition: none;
  }
}

/* ── ZeroPlain Auth UI ────────────────────────────────────────────────────── */

.nc-auth-screen {
  display: flex;
  min-height: calc(100vh - 64px);
  background: var(--bg-primary, #09090b);
}

.nc-auth-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 40px;
  padding: 48px;
  background: #111113;
  border-right: 1px solid rgba(255,255,255,0.06);
}

.nc-auth-left-copy {
  max-width: 380px;
  text-align: center;
}
.nc-auth-left-copy h2 {
  font-size: 1.6rem;
  font-weight: 700;
  color: #f4f4f5;
  line-height: 1.3;
  margin: 0 0 12px;
}
.nc-auth-left-copy p {
  color: #71717a;
  font-size: 0.93rem;
  line-height: 1.6;
  margin: 0;
}

.nc-auth-right {
  width: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 32px;
}

.nc-auth-card {
  width: 100%;
  max-width: 400px;
  background: #18181b;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 32px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.4);
}

.nc-auth-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
  font-size: 1.1rem;
  font-weight: 700;
  color: #f4f4f5;
}

.nc-auth-card h1 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #f4f4f5;
  margin: 0 0 6px;
}
.nc-auth-card h2 {
  font-size: 1.35rem;
  font-weight: 700;
  color: #f4f4f5;
  margin: 0 0 6px;
}

.nc-auth-subtitle {
  color: #71717a;
  font-size: 0.875rem;
  margin: 0 0 24px;
  line-height: 1.5;
}

/* Google Button */
.nc-google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 10px 16px;
  background: #fff;
  border: 1px solid #e4e4e7;
  border-radius: 8px;
  color: #18181b;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
  margin-bottom: 20px;
  font-family: inherit;
}
.nc-google-btn:hover {
  background: #f9fafb;
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
}

/* Divider */
.nc-auth-divider {
  position: relative;
  text-align: center;
  margin: 4px 0 20px;
}
.nc-auth-divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: rgba(255,255,255,0.08);
}
.nc-auth-divider span {
  position: relative;
  background: #18181b;
  padding: 0 12px;
  color: #52525b;
  font-size: 0.8rem;
}

/* Form fields */
.nc-auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.nc-auth-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.nc-auth-field label {
  font-size: 0.83rem;
  font-weight: 500;
  color: #a1a1aa;
}
.nc-auth-field input,
.nc-input-at input {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  background: #09090b;
  border: 1px solid #3f3f46;
  border-radius: 8px;
  color: #f4f4f5;
  font-size: 0.9rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s;
  box-sizing: border-box;
}
.nc-auth-field input:focus,
.nc-input-at input:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59,130,246,0.2);
}
.nc-auth-field input::placeholder {
  color: #52525b;
}

/* Password wrapper */
.nc-pw-wrap {
  position: relative;
}
.nc-pw-wrap input {
  padding-right: 40px;
}
.nc-pw-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: #71717a;
  padding: 4px;
  display: flex;
  align-items: center;
}
.nc-pw-toggle:hover { color: #a1a1aa; }

/* @ handle input */
.nc-input-at {
  display: flex;
  align-items: center;
  background: #09090b;
  border: 1px solid #3f3f46;
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 0.15s;
}
.nc-input-at:focus-within {
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59,130,246,0.2);
}
.nc-input-at span {
  padding: 0 10px;
  color: #52525b;
  font-size: 0.9rem;
  user-select: none;
}
.nc-input-at input {
  border: none;
  border-radius: 0;
  padding-left: 0;
  background: transparent;
  box-shadow: none;
}
.nc-input-at input:focus {
  border-color: transparent;
  box-shadow: none;
}

/* Field errors */
.nc-field-error {
  font-size: 0.78rem;
  color: #f87171;
  margin-top: 2px;
}
.nc-auth-error {
  font-size: 0.83rem;
  color: #f87171;
  background: rgba(239,68,68,0.08);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 6px;
  padding: 8px 12px;
  margin: 0;
}

/* Submit button */
.nc-auth-submit {
  width: 100%;
  height: 40px;
  background: #3b82f6;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s, transform 0.1s;
  margin-top: 4px;
}
.nc-auth-submit:hover { background: #2563eb; }
.nc-auth-submit:active { transform: scale(0.98); }
.nc-auth-submit:disabled { background: #27272a; color: #52525b; cursor: not-allowed; }

/* Toggle + Forgot */
.nc-auth-toggle {
  text-align: center;
  margin: 16px 0 0;
  font-size: 0.83rem;
  color: #71717a;
}
.nc-auth-toggle button,
.nc-auth-forgot button,
.nc-back-link,
.nc-link-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: #3b82f6;
  font-size: 0.83rem;
  font-family: inherit;
  padding: 0;
  text-decoration: none;
}
.nc-auth-toggle button:hover,
.nc-auth-forgot button:hover,
.nc-link-btn:hover { text-decoration: underline; }
.nc-auth-forgot {
  text-align: center;
  margin: 8px 0 0;
}

/* Email sent card */
.nc-email-sent-card {
  text-align: center;
}
.nc-sent-icon {
  margin-bottom: 20px;
  display: flex;
  justify-content: center;
}
.nc-email-sent-card h2 {
  margin-bottom: 8px;
}
.nc-email-sent-card p {
  color: #71717a;
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 20px;
}
.nc-email-sent-card .nc-link-btn {
  display: block;
  margin: 8px auto 0;
}

/* Forgot success */
.nc-forgot-success {
  color: #10b981;
  font-size: 0.85rem;
  margin-top: 12px;
  text-align: center;
}

/* Profile setup */
.nc-profile-screen {
  justify-content: center;
  align-items: center;
}
.nc-profile-card {
  max-width: 440px;
}
.nc-profile-avatar-preview {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #3b82f6;
  color: #fff;
  font-size: 1.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  transition: background 0.2s;
  user-select: none;
}

/* Color swatches */
.nc-color-swatches {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.nc-swatch {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s;
  padding: 0;
}
.nc-swatch:hover { transform: scale(1.15); }
.nc-swatch.selected {
  border-color: #fff;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.3);
  transform: scale(1.1);
}

.nc-back-link {
  display: inline-block;
  margin-bottom: 16px;
  font-size: 0.83rem;
}

/* Responsive */
@media (max-width: 768px) {
  .nc-auth-screen {
    flex-direction: column;
  }
  .nc-auth-left {
    display: none;
  }
  .nc-auth-right {
    width: 100%;
    padding: 24px 16px;
    align-items: flex-start;
    padding-top: 32px;
  }
  .nc-auth-card {
    border: none;
    background: transparent;
    box-shadow: none;
    padding: 0;
  }
}

/* Avatar Upload & Cropper */
.nc-profile-avatar-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
  gap: 8px;
}
.nc-profile-avatar-preview {
  position: relative;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: #3b82f6;
  color: #fff;
  font-size: 1.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  cursor: pointer;
  user-select: none;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  overflow: visible;
}
.nc-profile-avatar-preview:hover {
  transform: scale(1.04);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.45);
}
.nc-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}
.nc-avatar-badge {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #27272a;
  border: 2px solid #18181b;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #e4e4e7;
  box-shadow: 0 2px 6px rgba(0,0,0,0.4);
  transition: background 0.15s, color 0.15s;
}
.nc-profile-avatar-preview:hover .nc-avatar-badge {
  background: #3b82f6;
  color: #fff;
}
.nc-avatar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.nc-avatar-link-btn {
  background: none;
  border: none;
  color: #3b82f6;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  transition: color 0.15s;
}
.nc-avatar-link-btn:hover {
  color: #60a5fa;
  text-decoration: underline;
}
.nc-avatar-link-btn.danger {
  color: #ef4444;
}
.nc-avatar-link-btn.danger:hover {
  color: #f87171;
}

/* Crop Modal */
.nc-crop-dialog {
  border: none;
  border-radius: 16px;
  background: transparent;
  padding: 0;
  max-width: 360px;
  width: 90%;
}
.nc-crop-dialog::backdrop {
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
}
.nc-crop-card {
  background: #18181b;
  border: 1px solid #27272a;
  border-radius: 16px;
  padding: 20px;
  color: #f4f4f5;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
}
.nc-crop-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}
.nc-crop-head h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
}
.nc-crop-hint {
  font-size: 0.78rem;
  color: #a1a1aa;
  margin: 0 0 16px 0;
  text-align: center;
}
.nc-crop-viewport {
  position: relative;
  width: 280px;
  height: 280px;
  margin: 0 auto 16px;
  border-radius: 12px;
  overflow: hidden;
  background: #09090b;
  cursor: grab;
  user-select: none;
  touch-action: none;
}
.nc-crop-viewport:active {
  cursor: grabbing;
}
.nc-crop-viewport canvas {
  display: block;
  width: 280px;
  height: 280px;
}
.nc-crop-mask {
  position: absolute;
  inset: 30px;
  border-radius: 50%;
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.65);
  border: 2px dashed rgba(255, 255, 255, 0.65);
  pointer-events: none;
}
.nc-crop-zoom-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  padding: 0 10px;
}
.nc-zoom-btn {
  background: none;
  border: none;
  color: #a1a1aa;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 4px;
  transition: color 0.15s;
}
.nc-zoom-btn:hover {
  color: #fff;
}
.nc-crop-zoom-bar input[type="range"] {
  flex: 1;
  accent-color: #3b82f6;
  cursor: pointer;
}
.nc-crop-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}
