/* GOOGLE FONT LOOK */
*{
  margin:0;
  padding:0;
  box-sizing:border-box;
  font-family:'Poppins',sans-serif;
  scroll-behavior:smooth;
}

/* BODY */
body{
  min-height:100vh;
  background:linear-gradient(120deg,#f8fafc,#eef2ff);
  color:#111827;
  transition:0.4s;
}

/* DARK MODE */
body.dark{
  background:linear-gradient(120deg,#020617,#0f172a);
  color:#e5e7eb;
}

/* HEADER */
header{
  position:sticky;
  top:0;
  backdrop-filter: blur(12px);
  background:rgba(255,255,255,0.65);
  border-bottom:1px solid #e5e7eb;
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:18px 40px;
  z-index:100;
}

body.dark header{
  background:rgba(15,23,42,0.7);
  border-color:#1f2933;
}

header h1{
  font-size:24px;
  font-weight:700;
  letter-spacing:1px;
}

/* NAV */
nav{
  text-align:center;
  padding:15px;
}

nav a{
  position:relative;
  margin:0 15px;
  text-decoration:none;
  font-weight:600;
  color:#4b5563;
}

nav a::after{
  content:"";
  position:absolute;
  bottom:-5px;
  left:0;
  width:0%;
  height:2px;
  background:#6366f1;
  transition:0.3s;
}

nav a:hover::after{
  width:100%;
}

/* HERO */
.hero{
  text-align:center;
  padding:90px 20px;
}

.hero h2{
  font-size:42px;
  background:linear-gradient(135deg,#6366f1,#a855f7);
  -webkit-background-clip:text;
  color:transparent;
}

.hero p{
  margin-top:10px;
  opacity:0.8;
}

/* BUTTON */
button{
  border:none;
  padding:12px 22px;
  border-radius:10px;
  cursor:pointer;
  font-weight:600;
  background:linear-gradient(135deg,#6366f1,#a855f7);
  color:white;
  transition:0.3s;
  box-shadow:0 5px 15px rgba(99,102,241,0.3);
}

button:hover{
  transform:translateY(-2px) scale(1.05);
  box-shadow:0 10px 25px rgba(99,102,241,0.5);
}

/* INPUT */
input{
  padding:12px;
  border-radius:10px;
  border:1px solid #d1d5db;
  outline:none;
  transition:0.3s;
}

input:focus{
  border-color:#6366f1;
  box-shadow:0 0 0 3px rgba(99,102,241,0.2);
}

/* LOGIN CENTER */
.center{
  text-align:center;
  margin-top:120px;
}

/* CARDS */
.card{
  background:white;
  border-radius:16px;
  padding:25px;
  margin:25px;
  box-shadow:0 10px 30px rgba(0,0,0,0.08);
  transition:0.3s;
}

.card:hover{
  transform:translateY(-5px);
}

body.dark .card{
  background:#1f2937;
}

/* TOPICS */
.topicList{
  list-style:none;
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:20px;
  margin-top:40px;
}

.topicList a{
  text-decoration:none;
  padding:14px 22px;
  border-radius:12px;
  background:white;
  box-shadow:0 5px 20px rgba(0,0,0,0.08);
  font-weight:600;
  transition:0.3s;
}

.topicList a:hover{
  background:#6366f1;
  color:white;
}

/* CODE BLOCK */
pre{
  background:#020617;
  color:#22c55e;
  padding:18px;
  border-radius:12px;
  overflow:auto;
  font-size:14px;
  box-shadow:inset 0 0 15px rgba(0,0,0,0.6);
}

/* ANIMATION */
.fade{
  animation:fadeIn 0.7s ease;
}

@keyframes fadeIn{
  from{opacity:0;transform:translateY(20px)}
  to{opacity:1;transform:translateY(0)}
}

/* SCROLLBAR */
::-webkit-scrollbar{
  width:8px;
}
::-webkit-scrollbar-thumb{
  background:#6366f1;
  border-radius:10px;
}

/* MOBILE */
@media(max-width:768px){
  header{
    flex-direction:column;
    gap:10px;
  }
  .hero h2{
    font-size:30px;
  }
}
/* LINK BUTTON STYLE */
.btn-link{
  text-decoration:none;
  display:inline-block;
}

/* BACK BUTTON */
.back-btn{
  position:fixed;
  bottom:20px;
  left:20px;
  background:linear-gradient(135deg,#334155,#1f2933);
  color:white;
  padding:10px 18px;
  border-radius:10px;
  border:none;
  cursor:pointer;
  font-weight:600;
  box-shadow:0 5px 15px rgba(0,0,0,0.3);
  transition:0.3s;
}

.back-btn:hover{
  transform:scale(1.05);
}
/* TOPIC PAGE CONTAINER */
.topic-container{
  max-width:900px;
  margin:40px auto;
  padding:30px;
}

/* OUTPUT BOX */
.output{
  margin-top:15px;
  background:#111827;
  color:#e5e7eb;
  padding:15px;
  border-radius:10px;
  font-weight:600;
}

body.dark .output{
  background:#020617;
}

/* BUTTON WRAPPER */
.btns{
  margin-top:20px;
}

/* FOOTER CREDENTIAL CARD */
.cred-card{
  margin:60px auto;
  max-width:500px;
  text-align:center;
  padding:25px;
  border-radius:16px;
  background:rgba(255,255,255,0.2);
  backdrop-filter:blur(12px);
  box-shadow:0 8px 25px rgba(0,0,0,0.2);
}

body.dark .cred-card{
  background:rgba(31,41,55,0.7);
}

.links a{
  text-decoration:none;
  margin:0 12px;
  font-weight:600;
  color:#7c3aed;
}

.links a:hover{
  color:#6366f1;
}

/* TOPIC GRID BUTTONS */
.topicGrid{
  display:flex;
  flex-wrap:wrap;
  gap:20px;
  justify-content:center;
  margin-top:30px;
}

.btn{
  padding:14px 24px;
  border-radius:12px;
  background:linear-gradient(135deg,#6366f1,#a855f7);
  color:white;
  text-decoration:none;
  font-weight:600;
  transition:0.3s;
}

.btn:hover{
  transform:scale(1.05);
}

/* SMALL TEXT */
.small{
  font-size:14px;
  opacity:0.8;
  margin-top:10px;
}

/* SUBTITLE */
.subtitle{
  opacity:0.8;
  margin-bottom:25px;
}
