/*
Theme Name: MyAI.ma Theme
Theme URI: https://myai.ma
Author: AITIM.TECH
Author URI: https://aitim.ma
Description: Theme moderne pour MyAI.ma - Assistant IA
Version: 1.0
Text Domain: myai
*/

*{
  margin:0;
  padding:0;
  box-sizing:border-box;
  font-family:'Segoe UI',sans-serif;
}

body{
  min-height:100vh;
  background:
    radial-gradient(circle at top left,#7c3aed55,transparent 35%),
    radial-gradient(circle at bottom right,#06b6d455,transparent 35%),
    linear-gradient(135deg,#020617,#0f172a,#111827);
  color:white;
  overflow-x:hidden;
}

.myai-header{
  padding:22px 8%;
  display:flex;
  justify-content:space-between;
  align-items:center;
}

.logo{
  font-size:28px;
  font-weight:900;
  background:linear-gradient(90deg,#38bdf8,#a78bfa,#facc15);
  -webkit-background-clip:text;
  color:transparent;
  text-decoration:none;
}

.myai-nav a{
  color:#cbd5e1;
  text-decoration:none;
  margin-left:25px;
  font-weight:500;
}

.myai-nav a:hover{
  color:white;
}

.hero{
  display:grid;
  grid-template-columns:1fr 440px;
  gap:40px;
  align-items:center;
  padding:70px 8%;
}

.badge{
  display:inline-block;
  padding:10px 18px;
  border:1px solid #38bdf855;
  border-radius:50px;
  color:#67e8f9;
  background:#0f172a99;
  margin-bottom:25px;
}

h1{
  font-size:58px;
  line-height:1.1;
  margin-bottom:25px;
}

h1 span{
  background:linear-gradient(90deg,#38bdf8,#a78bfa,#facc15);
  -webkit-background-clip:text;
  color:transparent;
}

.desc{
  color:#cbd5e1;
  font-size:18px;
  line-height:1.8;
  max-width:650px;
  margin-bottom:30px;
}

.buttons{
  display:flex;
  gap:15px;
  flex-wrap:wrap;
}

.btn{
  position:relative;
  overflow:hidden;
  padding:14px 24px;
  border-radius:14px;
  border:none;
  cursor:pointer;
  font-weight:700;
  color:white;
  background:linear-gradient(135deg,#2563eb,#7c3aed);
  box-shadow:0 15px 35px #0006;
  transition:.3s;
}

.btn.secondary{
  background:#ffffff14;
  border:1px solid #ffffff22;
}

.btn:hover{
  transform:translateY(-4px) scale(1.04);
}

.btn::before{
  content:"";
  position:absolute;
  top:0;
  left:-120%;
  width:60%;
  height:100%;
  background:linear-gradient(90deg,transparent,#ffffff66,transparent);
  animation:shine 2.8s infinite;
}

.chatbox{
  background:rgba(255,255,255,0.09);
  backdrop-filter:blur(20px);
  border:1px solid rgba(255,255,255,0.18);
  border-radius:30px;
  padding:20px;
  box-shadow:0 30px 80px #0008;
  animation:floatCard 4s ease-in-out infinite, glow 3s ease-in-out infinite;
}

.chat-header{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  padding-bottom:15px;
  border-bottom:1px solid #ffffff18;
}

.chat-title{
  display:flex;
  align-items:center;
  gap:12px;
}

.bot-icon{
  width:48px;
  height:48px;
  border-radius:15px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,#38bdf8,#7c3aed);
  font-size:24px;
  animation:pulseBot 2s ease-in-out infinite;
}

.chat-header small{
  color:#94a3b8;
}

.clear-chat{
  width:42px;
  height:42px;
  border:none;
  border-radius:14px;
  cursor:pointer;
  font-size:18px;
  color:white;
  background:linear-gradient(135deg,#ef4444,#dc2626);
  transition:.3s;
  box-shadow:0 10px 25px #ef444455;
}

.clear-chat:hover{
  transform:scale(1.1) rotate(8deg);
}

.chat-body{
  height:390px;
  overflow-y:auto;
  padding:18px 5px;
}

.msg{
  max-width:85%;
  padding:13px 15px;
  border-radius:18px;
  margin-bottom:12px;
  line-height:1.5;
  font-size:14px;
  animation:fadeUp .35s ease;
}

.bot{
  background:#ffffff12;
  border:1px solid #ffffff18;
  color:#e2e8f0;
}

.user{
  background:linear-gradient(135deg,#2563eb,#7c3aed);
  margin-left:auto;
  color:white;
}

.quick{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-bottom:12px;
}

.quick button{
  border:none;
  padding:9px 12px;
  border-radius:999px;
  background:#ffffff12;
  color:#dbeafe;
  cursor:pointer;
}

.quick button:hover{
  background:#2563eb;
}

.chat-input{
  display:flex;
  gap:10px;
  padding-top:15px;
  border-top:1px solid #ffffff18;
}

.chat-input input{
  flex:1;
  padding:14px;
  border-radius:14px;
  border:1px solid #ffffff22;
  background:#02061799;
  color:white;
  outline:none;
}

.chat-input button{
  width:55px;
  border:none;
  border-radius:14px;
  cursor:pointer;
  background:linear-gradient(135deg,#38bdf8,#7c3aed);
  color:white;
  font-size:20px;
}

.cards{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:20px;
  padding:20px 8% 60px;
}

.card{
  background:#ffffff0d;
  border:1px solid #ffffff18;
  border-radius:24px;
  padding:25px;
  backdrop-filter:blur(15px);
  animation:fadeUp .9s ease forwards;
  transition:.4s;
}

.card:hover{
  transform:translateY(-10px) scale(1.03);
  background:#ffffff18;
}

.card h3{
  margin-bottom:12px;
}

.card p{
  color:#cbd5e1;
  line-height:1.6;
}

.myai-footer{
  padding:25px 8%;
  border-top:1px solid #ffffff18;
  text-align:center;
  color:#94a3b8;
  font-size:14px;
}

@keyframes floatCard{
  0%,100%{transform:translateY(0)}
  50%{transform:translateY(-14px)}
}

@keyframes glow{
  0%,100%{box-shadow:0 0 25px #38bdf855}
  50%{box-shadow:0 0 55px #a78bfa99}
}

@keyframes fadeUp{
  from{opacity:0;transform:translateY(30px)}
  to{opacity:1;transform:translateY(0)}
}

@keyframes pulseBot{
  0%,100%{transform:scale(1)}
  50%{transform:scale(1.08)}
}

@keyframes shine{
  from{left:-120%}
  to{left:120%}
}

@media(max-width:900px){
  .myai-header{
    padding:18px 6%;
  }

  .myai-nav{
    display:none;
  }

  .hero{
    grid-template-columns:1fr;
    padding:30px 6% 60px;
  }

  h1{
    font-size:40px;
  }

  .chatbox{
    animation:glow 3s ease-in-out infinite;
  }
}

@media(max-width:520px){
  h1{
    font-size:34px;
  }

  .desc{
    font-size:16px;
  }

  .chat-body{
    height:360px;
  }

  .msg{
    max-width:92%;
  }

  .buttons{
    flex-direction:column;
  }

  .btn{
    width:100%;
  }
}