/* NEVO CX360 landing page — base styles.
   Layout and component styles are inline in index.html, exported 1:1 from the approved design.
   Design tokens are listed below for refactoring into your component system (see README). */

/* ---------- Fonts (self-hosted) ---------- */
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 400; font-display: swap; src: url('../assets/fonts/poppins-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 500; font-display: swap; src: url('../assets/fonts/poppins-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 600; font-display: swap; src: url('../assets/fonts/poppins-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 700; font-display: swap; src: url('../assets/fonts/poppins-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-style: normal; font-weight: 700; font-display: swap; src: url('../assets/fonts/jost-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Noto Kufi Arabic'; font-style: normal; font-weight: 400; font-display: swap; src: url('../assets/fonts/noto-kufi-arabic-arabic-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Noto Kufi Arabic'; font-style: normal; font-weight: 600; font-display: swap; src: url('../assets/fonts/noto-kufi-arabic-arabic-600-normal.woff2') format('woff2'); }

/* ---------- Design tokens ---------- */
:root {
  --cx-ink: #0B1A2C;          /* dark section background */
  --cx-ink-2: #12263D;        /* dark surface / cards */
  --cx-ink-3: #183049;        /* dark raised / chips */
  --cx-line-dark: #23405F;    /* borders on dark */
  --cx-primary: #0D7F75;      /* teal — buttons, links, active */
  --cx-primary-dark: #08605A; /* hover */
  --cx-accent: #5EEAD4;       /* bright teal — highlights on dark only */
  --cx-brand-blue: #073D69;   /* NEVO wordmark blue */
  --cx-text: #0F1B26;
  --cx-text-2: #44515E;
  --cx-text-3: #586674;
  --cx-text-on-dark: #B7C6D6;
  --cx-muted-on-dark: #8FA3B8;
  --cx-surface: #F2F7F9;      /* light section background */
  --cx-line: #E3EAEE;
  --cx-success: #5BD08A;
  --cx-ai: #6D3FD6;           /* AI step */
  --cx-action: #2563B8;       /* action step */
  --cx-trigger: #4E6A8E;
  --cx-condition: #9A5B1E;
  --cx-expert-bg: #E4EDFB;
  --cx-ai-bubble: #DDF3EF;
  --cx-radius-sm: 10px;
  --cx-radius-md: 14px;
  --cx-radius-lg: 18px;
  --cx-radius-xl: 24px;
  --cx-container: 1240px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: #FFFFFF; -webkit-font-smoothing: antialiased; }
a { color: var(--cx-primary); }
a:hover { color: var(--cx-primary-dark); }
img { max-width: 100%; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid var(--cx-accent); outline-offset: 2px; }

/* ---------- Motion ---------- */
.cx-dot { width: 7px; height: 7px; border-radius: 50%; background: #8A8696; display: inline-block; animation: cxBlink 1.2s infinite; }
.cx-dot:nth-child(2) { animation-delay: .2s; }
.cx-dot:nth-child(3) { animation-delay: .4s; }
@keyframes cxBlink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }

.cx-pulse { animation: cxPulse 1.4s infinite; }
@keyframes cxPulse { 0% { box-shadow: 0 0 0 0 rgba(13,127,117,.45); } 70% { box-shadow: 0 0 0 12px rgba(13,127,117,0); } 100% { box-shadow: 0 0 0 0 rgba(13,127,117,0); } }

.cx-in { animation: cxIn .4s ease-out; }
@keyframes cxIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.cx-live { animation: cxLive 1.6s infinite; }
@keyframes cxLive { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

.cx-marquee { display: flex; gap: 40px; width: max-content; animation: cxScroll 60s linear infinite; }
@keyframes cxScroll { to { transform: translateX(-50%); } }

.cx-bar { transition: width .6s ease; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .cx-dot, .cx-pulse, .cx-in, .cx-live, .cx-marquee { animation: none; }
}

.mobile-nav-actions { display: none; }

@media (max-width: 760px) {
  .site-nav {
    padding: 10px 12px !important;
    column-gap: 8px !important;
  }

  .site-nav .site-brand,
  .site-nav .site-brand > span { gap: 5px !important; }
  .site-nav .site-brand > img { height: 18px !important; width: 34px !important; }
  .site-nav .site-brand > span > img { height: 19px !important; width: 66px !important; }
  .site-nav .site-brand > span > span { font-size: 26px !important; }

  .mobile-nav-actions { display: flex; align-items: center; gap: 6px; }
  .mobile-nav-actions .nav-demo,
  #nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border-radius: 10px;
  }

  .mobile-nav-actions .nav-demo {
    padding: 0 9px;
    background: var(--cx-primary);
    color: white;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
  }

  #nav-toggle {
    width: 44px;
    background: white;
    color: var(--cx-brand-blue);
    border: 1px solid var(--cx-line);
    cursor: pointer;
  }

  .site-nav #nav-links {
    flex: 1 1 100%;
    flex-direction: column;
    align-items: stretch !important;
    gap: 0 !important;
  }

  .site-nav:not(.is-open) #nav-links { display: none !important; }
  #nav-links > a, #nav-links > span { padding: 12px 4px; min-height: 44px; }
  #nav-links .desktop-nav-demo { display: none !important; }
}

#demo-form button:disabled { opacity: .7; cursor: wait !important; }

@media (max-width: 360px) {
  #demo-form { grid-template-columns: minmax(0, 1fr) !important; }
  body { overflow-wrap: anywhere; }
  .site-nav { padding-inline: 8px !important; column-gap: 4px !important; }
  .mobile-nav-actions { gap: 4px; }
  .site-nav .site-brand > img { width: 26px !important; height: 14px !important; }
  .site-nav .site-brand > span > img { width: 52px !important; height: 15px !important; }
  .site-nav .site-brand > span > span { font-size: 22px !important; }
  .mobile-nav-actions .nav-demo { padding-inline: 7px; font-size: 11px; }
}

[dir="rtl"] h1,
[dir="rtl"] h2 { line-height: 1.4 !important; letter-spacing: normal !important; }

[dir="rtl"] .cx-marquee { animation-name: cxScrollRtl; }
@keyframes cxScrollRtl { to { transform: translateX(50%); } }

[dir="rtl"] #chat-messages > div[dir="auto"] { text-align: start; }
[dir="rtl"] #chat-messages > div:not([dir]) > div:first-child { direction: rtl; }
[dir="rtl"] #run-log > div > span:first-child { direction: ltr; }

@media (max-width: 900px) {
  [dir="rtl"] .site-nav { row-gap: 10px; }
  [dir="rtl"] #nav-links { column-gap: 12px !important; }
}
