:root{
  --bg:#0A0F1C;
  --bg-alt:#0F1729;
  --surface:#141F38;
  --surface-2:#182645;
  --border:rgba(255,255,255,.09);
  --text:#F2EFE7;
  --muted:#8C93AC;
  --accent:#FF9B4A;
  --accent-ink:#2A1400;
  --accent-2:#4FD1C5;
  --radius:6px;
  --wrap:1120px;
}

*{box-sizing:border-box;}
html{scroll-behavior:smooth;}
body{
  margin:0;
  background:var(--bg);
  color:var(--text);
  font-family:'Inter',system-ui,sans-serif;
  line-height:1.55;
  -webkit-font-smoothing:antialiased;
}
h1,h2,h3{
  font-family:'Fraunces',Georgia,serif;
  font-weight:500;
  line-height:1.12;
  margin:0 0 .5em;
  letter-spacing:-.01em;
}
h2{font-size:clamp(1.7rem,3vw,2.4rem);}
p{color:var(--muted); margin:0 0 1em;}
a{color:inherit;}
.wrap{max-width:var(--wrap); margin:0 auto; padding:0 24px;}
img{max-width:100%;display:block;}
:focus-visible{outline:2px solid var(--accent-2); outline-offset:3px;}
@media (prefers-reduced-motion: reduce){
  *{animation-duration:.001ms !important; animation-iteration-count:1 !important; transition-duration:.001ms !important; scroll-behavior:auto !important;}
}

/* ---------- loader (single orchestrated moment) ---------- */
.signal-loader{
  position:fixed; inset:0; z-index:999; background:var(--bg);
  display:flex; align-items:center; justify-content:center; gap:6px;
  animation:loader-out .5s ease 1.1s forwards;
}
.signal-loader span{
  width:5px; height:28px; background:var(--accent-2); border-radius:3px;
  animation:loader-bar 1s ease-in-out infinite;
}
.signal-loader span:nth-child(2){animation-delay:.1s;}
.signal-loader span:nth-child(3){animation-delay:.2s;}
.signal-loader span:nth-child(4){animation-delay:.3s;}
.signal-loader span:nth-child(5){animation-delay:.4s;}
@keyframes loader-bar{0%,100%{transform:scaleY(.3);}50%{transform:scaleY(1);}}
@keyframes loader-out{to{opacity:0; visibility:hidden; pointer-events:none;}}

/* ---------- header ---------- */
.site-header{
  position:sticky; top:0; z-index:50;
  background:rgba(10,15,28,.85); backdrop-filter:blur(10px);
  border-bottom:1px solid var(--border);
}
.header-row{display:flex; align-items:center; gap:28px; height:72px;}
.brand{display:flex; align-items:center; gap:10px; text-decoration:none; font-family:'Fraunces',serif; font-size:1.2rem; margin-right:auto;}
.brand-mark{display:inline-flex; align-items:flex-end; gap:2px; height:18px;}
.brand-mark i{width:3px; background:var(--accent); border-radius:2px; display:block;}
.brand-mark i:nth-child(1){height:60%;}
.brand-mark i:nth-child(2){height:100%; background:var(--accent-2);}
.brand-mark i:nth-child(3){height:75%;}
.brand-name{color:var(--text);}
.main-nav{display:flex; gap:26px;}
.main-nav a{text-decoration:none; color:var(--muted); font-size:.95rem; transition:color .15s;}
.main-nav a:hover{color:var(--text);}
.nav-toggle{display:none; flex-direction:column; gap:4px; background:none; border:0; cursor:pointer; padding:8px;}
.nav-toggle span{width:22px; height:2px; background:var(--text);}

.btn{
  display:inline-flex; align-items:center; justify-content:center;
  padding:13px 24px; border-radius:var(--radius); text-decoration:none;
  font-weight:600; font-size:.95rem; border:1px solid transparent; cursor:pointer;
  transition:transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn:hover{transform:translateY(-1px);}
.btn-primary{background:var(--accent); color:var(--accent-ink);}
.btn-primary:hover{background:#ffab66;}
.btn-ghost{border-color:var(--border); color:var(--text);}
.btn-ghost:hover{border-color:var(--accent-2);}
.btn-small{padding:9px 18px; font-size:.88rem;}

/* ---------- hero ---------- */
.hero{padding:88px 0 96px; border-bottom:1px solid var(--border);}
.hero-row{display:grid; grid-template-columns:1.15fr .85fr; gap:56px; align-items:center;}
.eyebrow{color:var(--accent-2); font-size:.9rem; margin-bottom:14px;}
.hero-copy h1{font-size:clamp(2.4rem,4.4vw,3.6rem); max-width:12ch;}
.hero-sub{font-size:1.08rem; max-width:46ch; margin-bottom:2em;}
.hero-actions{display:flex; gap:14px; flex-wrap:wrap;}

.call-card{
  background:var(--surface); border:1px solid var(--border); border-radius:14px;
  padding:26px; max-width:360px; margin-left:auto;
  box-shadow:0 30px 60px -30px rgba(0,0,0,.6);
}
.call-card-top{display:flex; align-items:center; gap:10px; font-size:.9rem; color:var(--muted); margin-bottom:22px;}
.call-dot{width:8px; height:8px; border-radius:50%; background:var(--accent-2); box-shadow:0 0 0 4px rgba(79,209,197,.18);}
.waveform{display:flex; align-items:center; gap:4px; height:70px; margin:0 0 22px;}
.waveform i{flex:1; background:linear-gradient(var(--accent-2),var(--accent)); border-radius:3px; animation:wave 1.4s ease-in-out infinite;}
@keyframes wave{0%,100%{transform:scaleY(.25);}50%{transform:scaleY(1);}}
.call-card-bottom{display:flex; justify-content:space-between; font-size:.85rem; color:var(--muted); border-top:1px solid var(--border); padding-top:16px;}

/* ---------- section shared ---------- */
section{padding:88px 0;}
.section-sub{max-width:52ch; font-size:1.05rem; margin-bottom:3em;}

/* ---------- business models ---------- */
.models{border-bottom:1px solid var(--border);}
.models-grid{display:grid; grid-template-columns:repeat(3,1fr); gap:1px; background:var(--border); border:1px solid var(--border); border-radius:var(--radius); overflow:hidden;}
.model-card{background:var(--bg-alt); padding:32px 28px; border-top:3px solid var(--accent);}
.model-card:nth-child(2){border-top-color:var(--accent-2);}
.model-card:nth-child(3){border-top-color:#7C8BFF;}
.model-card h3{font-size:1.2rem; margin-bottom:.5em;}
.model-card p{margin:0; font-size:.96rem;}

/* ---------- features ---------- */
.features-list{border-top:1px solid var(--border);}
.feature-row{display:grid; grid-template-columns:40px 1fr; gap:20px; padding:26px 0; border-bottom:1px solid var(--border);}
.feature-row .mini-wave{display:flex; align-items:flex-end; gap:2px; height:22px; margin-top:4px;}
.feature-row .mini-wave i{width:3px; background:var(--accent-2); border-radius:2px;}
.feature-row h3{font-size:1.05rem; margin-bottom:.3em; font-family:'Inter',sans-serif; font-weight:600;}
.feature-row p{margin:0; font-size:.95rem;}

/* ---------- integrations ---------- */
.integrations{background:var(--bg-alt); border-top:1px solid var(--border); border-bottom:1px solid var(--border);}
.integration-group{margin-bottom:28px;}
.integration-group h4{font-size:.85rem; color:var(--muted); text-transform:none; margin:0 0 12px; font-weight:600;}
.badge-row{display:flex; flex-wrap:wrap; gap:10px;}
.badge{
  border:1px solid var(--border); border-radius:100px; padding:8px 16px;
  font-size:.87rem; color:var(--text); background:var(--surface);
}

/* ---------- stack ---------- */
.stack-grid{display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:24px;}
.stack-grid .item{padding:20px 0; border-top:1px solid var(--border);}
.stack-grid .item strong{display:block; font-size:.82rem; color:var(--accent-2); margin-bottom:6px; font-weight:600;}
.stack-grid .item span{color:var(--text); font-size:.95rem;}

/* ---------- contact ---------- */
.contact-row{display:grid; grid-template-columns:1fr 1fr; gap:64px;}
.contact-list{list-style:none; padding:0; margin:0 0 20px; border-top:1px solid var(--border);}
.contact-list li{display:flex; justify-content:space-between; gap:16px; padding:14px 0; border-bottom:1px solid var(--border); font-size:.95rem;}
.contact-list li span:first-child{color:var(--muted);}
.contact-list a{text-decoration:none;}
.contact-list a:hover{color:var(--accent-2);}
.socials{display:flex; gap:14px;}
.socials a{font-size:.85rem; color:var(--muted); text-decoration:none; border-bottom:1px solid var(--border);}

.contact-form{background:var(--surface); border:1px solid var(--border); border-radius:var(--radius); padding:28px;}
.contact-form label{display:block; font-size:.85rem; color:var(--muted); margin-bottom:16px;}
.contact-form input, .contact-form textarea{
  width:100%; margin-top:6px; padding:11px 13px; background:var(--bg-alt);
  border:1px solid var(--border); border-radius:4px; color:var(--text); font-family:inherit; font-size:.95rem;
}
.contact-form input:focus, .contact-form textarea:focus{border-color:var(--accent-2); outline:none;}
.form-note{font-size:.85rem; color:var(--accent-2); min-height:1.2em; margin:10px 0 0;}

/* ---------- demo call widget ---------- */
.demo{border-bottom:1px solid var(--border);}
.demo-layout{display:grid; grid-template-columns:1fr 1fr; gap:40px; align-items:start;}
.demo-setup h3{font-size:1rem; margin-bottom:14px; font-family:'Inter',sans-serif; font-weight:600;}
.demo-setup h3.spaced-heading{margin-top:26px;}
.lang-toggle{display:inline-flex; border:1px solid var(--border); border-radius:100px; padding:3px; margin-bottom:20px; gap:2px;}
.lang-btn{
  border:0; background:none; color:var(--muted); padding:7px 16px; border-radius:100px;
  font-size:.85rem; cursor:pointer; font-family:inherit;
}
.lang-btn.active{background:var(--accent); color:var(--accent-ink);}
.preset-row{display:flex; flex-wrap:wrap; gap:8px; margin-bottom:20px;}
.preset-chip{
  border:1px solid var(--border); background:var(--surface); color:var(--text);
  border-radius:100px; padding:8px 14px; font-size:.84rem; cursor:pointer; font-family:inherit;
}
.preset-chip:hover{border-color:var(--accent-2);}
.demo-setup label{display:block; font-size:.85rem; color:var(--muted); margin-bottom:14px;}
.demo-setup input, .demo-setup textarea{
  width:100%; margin-top:6px; padding:11px 13px; background:var(--surface);
  border:1px solid var(--border); border-radius:4px; color:var(--text); font-family:inherit; font-size:.92rem;
}
.demo-setup input:focus, .demo-setup textarea:focus{border-color:var(--accent-2); outline:none;}

.demo-call.hidden{display:none;}
.demo-card{margin:0 0 18px; max-width:none;}
.demo-card .waveform{height:36px; margin:0;}
.demo-transcript{
  background:var(--surface); border:1px solid var(--border); border-radius:8px;
  padding:16px; max-height:320px; overflow-y:auto; display:flex; flex-direction:column; gap:10px; margin-bottom:14px;
}
.demo-bubble{max-width:80%; padding:10px 14px; border-radius:10px; font-size:.9rem; line-height:1.5;}
.demo-bubble.agent{background:var(--surface-2); align-self:flex-start; border:1px solid var(--border);}
.demo-bubble.user{background:var(--accent); color:var(--accent-ink); align-self:flex-end;}
.demo-bubble.typing{color:var(--muted); font-style:italic;}
.demo-quick-replies{display:flex; flex-wrap:wrap; gap:8px; margin-bottom:14px;}
.demo-input-row{display:flex; gap:10px; margin-bottom:12px;}
.demo-input-row input{
  flex:1; padding:11px 13px; background:var(--surface); border:1px solid var(--border);
  border-radius:4px; color:var(--text); font-family:inherit; font-size:.92rem;
}
.demo-input-row input:focus{border-color:var(--accent-2); outline:none;}

/* Arabic / RTL handling \u2014 scoped to the demo widget only */
#demo [lang="ar"]{font-family:'Cairo','Inter',sans-serif;}
#demo[dir="rtl"] .demo-input-row,
#demo[dir="rtl"] .lang-toggle{direction:rtl;}
#demo[dir="rtl"] .demo-bubble{text-align:right;}

@media (max-width:860px){
  .demo-layout{grid-template-columns:1fr;}
}

/* ---------- footer ---------- */
.site-footer{border-top:1px solid var(--border); padding:26px 0; font-size:.85rem; color:var(--muted);}
.footer-row{display:flex; justify-content:space-between; align-items:center; gap:16px; flex-wrap:wrap;}
.admin-link{color:var(--muted); text-decoration:none; border-bottom:1px solid var(--border);}
.admin-link:hover{color:var(--text);}

/* ---------- responsive ---------- */
@media (max-width:860px){
  .hero-row{grid-template-columns:1fr;}
  .call-card{margin:0 auto;}
  .models-grid{grid-template-columns:1fr;}
  .contact-row{grid-template-columns:1fr;}
}
@media (max-width:720px){
  .main-nav, .btn.btn-small{display:none;}
  .nav-toggle{display:flex;}
  .main-nav.open{
    display:flex; position:absolute; top:72px; left:0; right:0; background:var(--bg-alt);
    flex-direction:column; padding:18px 24px; border-bottom:1px solid var(--border); gap:16px;
  }
  section{padding:64px 0;}
}
