*{
  box-sizing:border-box;
  margin:0;
  padding:0;
}
body{
  min-height:100vh;
  background:#080b12;
  color:#fff;
  font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  overflow:hidden;
}
.screen{
  display:none;
  min-height:100vh;
  width:100%;
}
.screen.active{
  display:flex;
}
#input-screen{
  align-items:center;
  justify-content:center;
  padding:18px;
  background:radial-gradient(circle at top,#263d5c,#080b12 70%);
}
.panel{
  width:min(660px,94vw);
  background:rgba(20,27,38,.95);
  border:1px solid rgba(255,255,255,.14);
  border-radius:24px;
  padding:24px;
  box-shadow:0 24px 70px rgba(0,0,0,.5);
}
.panel h1{
  font-size:2.25rem;
  line-height:1.05;
  margin-bottom:10px;
}
.panel h1 span{
  color:#00ffd5;
}
.lead{
  color:#c8d3e3;
  line-height:1.7;
  margin-bottom:18px;
}
label{
  display:block;
  color:#00ffd5;
  font-weight:900;
  margin-bottom:8px;
}
textarea{
  width:100%;
  min-height:110px;
  resize:vertical;
  border:2px solid #334155;
  border-radius:16px;
  background:#0d131c;
  color:#fff;
  padding:14px;
  font-size:1rem;
  margin-bottom:14px;
}
button{
  border:0;
  border-radius:16px;
  padding:14px 20px;
  font-weight:1000;
  cursor:pointer;
}
#show-effect{
  width:100%;
  color:#061015;
  background:linear-gradient(135deg,#00ffd5,#3aa8ff);
  font-size:1.1rem;
}
.sample-box{
  margin-top:16px;
  background:#0d131c;
  border-radius:16px;
  padding:14px;
  color:#d6e0ee;
  font-size:.92rem;
  line-height:1.55;
}
.sample-box h2{
  font-size:1.05rem;
  margin-bottom:8px;
}
.sample-box code{
  color:#00ffd5;
}

#effect-screen{
  position:relative;
  flex-direction:column;
  overflow:hidden;
  padding:18px;
}
#effect-bg{
  position:absolute;
  inset:0;
  z-index:-2;
  background:radial-gradient(circle at top,#162c4a,#05070b 70%);
}
#effect-bg::after{
  content:"";
  position:absolute;
  inset:-40%;
  background:
    linear-gradient(120deg,rgba(0,255,213,.16),transparent 40%),
    linear-gradient(250deg,rgba(255,209,102,.12),transparent 50%);
  animation:bgMove 9s linear infinite;
}
@keyframes bgMove{
  from{transform:rotate(0deg)}
  to{transform:rotate(360deg)}
}
#effect-header{
  text-align:center;
  padding:18px 8px 8px;
}
#effect-title{
  font-size:clamp(2rem,7vw,5rem);
  line-height:1;
  color:#ffd166;
  text-shadow:0 0 32px rgba(255,209,102,.45);
}
#effect-subtitle{
  margin-top:10px;
  color:#d8e4f2;
  font-size:clamp(.9rem,3vw,1.25rem);
}
#media-stage{
  flex:1;
  display:flex;
  align-items:center;
  justify-content:center;
  width:100%;
}
#media-grid{
  width:min(1100px,94vw);
  display:grid;
  gap:16px;
  align-items:center;
  justify-content:center;
}
.media-card{
  position:relative;
  overflow:hidden;
  min-height:160px;
  border-radius:24px;
  background:rgba(255,255,255,.08);
  border:1px solid rgba(255,255,255,.16);
  box-shadow:0 20px 60px rgba(0,0,0,.38);
  display:flex;
  align-items:center;
  justify-content:center;
}
.media-card img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.placeholder{
  width:100%;
  height:100%;
  min-height:180px;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-direction:column;
  text-align:center;
  padding:20px;
  background:
    radial-gradient(circle at 25% 20%,rgba(255,255,255,.18),transparent 28%),
    linear-gradient(135deg,rgba(0,255,213,.26),rgba(58,168,255,.16),rgba(255,209,102,.22));
}
.placeholder .big{
  font-size:clamp(2rem,6vw,4rem);
  font-weight:1000;
}
.placeholder .small{
  margin-top:8px;
  color:#f3f8ff;
  font-weight:800;
}
#result-info{
  display:grid;
  grid-template-columns:repeat(6,1fr);
  gap:8px;
  width:min(1100px,94vw);
  margin:0 auto 12px;
  background:rgba(10,15,24,.65);
  border:1px solid rgba(255,255,255,.12);
  border-radius:16px;
  padding:10px;
  color:#aebdd2;
  font-size:.78rem;
  text-align:center;
}
#result-info strong{
  color:#00ffd5;
}
#back-button{
  position:fixed;
  right:14px;
  bottom:14px;
  z-index:10;
  padding:10px 14px;
  border-radius:999px;
  background:rgba(255,255,255,.88);
  color:#081018;
  font-size:.82rem;
  box-shadow:0 8px 26px rgba(0,0,0,.35);
}
.level-1 #effect-title,.level-2 #effect-title{color:#a8b3c7}
.level-3 #effect-title,.level-4 #effect-title{color:#00ffd5}
.level-5 #effect-title,.level-6 #effect-title{color:#3aa8ff}
.level-7 #effect-title,.level-8 #effect-title{color:#ffd166}
.level-9 #effect-title,.level-10 #effect-title{color:#ff4d8d}

@media(max-width:760px){
  #result-info{
    grid-template-columns:1fr 1fr 1fr;
  }
  #media-grid{
    gap:10px;
  }
  .media-card{
    min-height:130px;
    border-radius:18px;
  }
}
@media(max-width:520px){
  #result-info{
    grid-template-columns:1fr 1fr;
  }
}
