/* ===== BODY ===== */
body {
    margin: 0;
    font-family: 'Segoe UI', sans-serif;
    background: radial-gradient(circle at top,#11163a,#070b24 60%, #030617);
    color: #fff;
    overflow-x: hidden;
    position: relative;
}

/* ===== BACK BUTTON ===== */
.back-btn-container { 
    padding: 20px 10%; 
    text-align: left; 
}

.back-btn { 
    display: inline-block; 
    padding: 10px 22px; 
    border-radius: 25px; 
    background: linear-gradient(45deg,#8ec5fc,#e0c3fc);
    color: #000; 
    text-decoration: none; 
    font-weight: bold; 
    transition: 0.3s; 
}

.back-btn:hover { 
    transform: scale(1.08);
    box-shadow:0 0 20px rgba(200,200,255,.6);
}

/* ===== PAGE SECTION ===== */
.projects-section { 
    padding: 50px 10%; 
    text-align: center; 
    position: relative; 
    z-index: 2;
    animation: pageLoad 1s ease;
}

.projects-section h1{
    font-size: 48px;
    margin-bottom: 10px;
    letter-spacing: 1px;
    background: linear-gradient(90deg,#7be7ff,#a18cd1,#ff9a9e);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientTitle 8s ease infinite;
}

.projects-section p {
    font-size: 18px;
    margin-bottom: 30px;
    color: #c9c9ff;
}

/* ===== SEMESTER BUTTONS ===== */
.semester-buttons { 
    display: flex; 
    justify-content: center; 
    gap: 20px; 
    flex-wrap: wrap; 
    margin-bottom: 50px; 
}

.semester-buttons button {
    padding: 12px 28px;
    border-radius: 30px;
    border: none;
    background: linear-gradient(45deg,#667eea,#764ba2);
    color: white;
    font-size: 16px;
    cursor: pointer;
    transition: 0.4s;
}

.semester-buttons button:hover { 
    transform: translateY(-4px);
    box-shadow:0 10px 30px rgba(150,150,255,.5);
}

.semester-buttons button:active{
    transform: scale(0.95);
}

/* Active Button */
.semester-buttons button.active-btn{
    background: linear-gradient(45deg,#ff7bff,#7be7ff);
    box-shadow:0 0 20px rgba(180,180,255,.7);
}

/* ===== SEMESTER VISIBILITY ===== */
.semester{
    display:none;
    opacity:0;
    transform: translateY(20px);
}

.semester.active{
    display:block;
    opacity:1;
    transform: translateY(0);
    animation: fadeSemester .6s ease;
}

.semester h2{
    margin-top: 60px;
    font-size: 32px;
    font-weight: 800;
    letter-spacing: .5px;
    background: linear-gradient(90deg,#ff9a9e,#fad0c4,#a18cd1);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientTitle 6s ease infinite;
}

@keyframes fadeSemester{
    from{opacity:0; transform:translateY(25px);}
    to{opacity:1; transform:translateY(0);}
}

/* ===== PROJECT GRID ===== */
.projects-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); 
    gap: 35px; 
}

/* ===== PROJECT BOX ===== */
.project-box {
    background: rgba(255,255,255,0.05);
    border-radius: 20px;
    padding: 25px;
    backdrop-filter: blur(14px);
    border: 1px solid rgba(200,200,255,0.2);
    box-shadow: 0 10px 25px rgba(0,0,0,0.6);
    opacity: 0;
    transform: translateY(40px) scale(0.95);
    animation: fadeIn 0.9s forwards;
    transition: all .5s ease;
}

.project-box:hover {
    transform: translateY(-15px) scale(1.07);
    box-shadow: 0 25px 60px rgba(120,140,255,0.8);
}

/* ===== PROJECT TITLE ===== */
.project-box h3 {
    font-size: 27px;
    font-weight: 800;
    margin-bottom: 14px;
    letter-spacing: .5px;
    background: linear-gradient(90deg,#a18cd1,#fbc2eb,#8ec5fc);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientTitle 6s ease infinite;
}

@keyframes gradientTitle {
    0%{background-position:0%}
    50%{background-position:100%}
    100%{background-position:0%}
}

.project-box p { 
    font-size: 15px; 
    color: #d6d6ff; 
}

/* ===== PROJECT IMAGE ===== */
.project-logo { 
    width: 70%; 
    max-width: 280px; 
    margin-top: 15px; 
    border-radius: 12px; 
    transition: transform .5s; 
}

.project-box:hover .project-logo { 
    transform: scale(1.15) rotate(3deg); 
}

/* ===== VIEW BUTTON ===== */
.view-btn {
    display: inline-block;
    margin-top: 12px;
    padding: 10px 22px;
    border-radius: 25px;
    background: linear-gradient(45deg,#8ec5fc,#e0c3fc);
    color:#000;
    text-decoration:none;
    font-weight:bold;
    transition:.3s;
}

.view-btn:hover {
    transform:scale(1.1);
    box-shadow:0 0 20px rgba(200,200,255,.6);
}

/* ===== FADE IN ===== */
@keyframes fadeIn { 
    to { opacity: 1; transform: translateY(0) scale(1); } 
}

.fade-in { animation: fadeIn 0.9s forwards; }

/* ===== EARTH ===== */
.earth {
    position: fixed;
    bottom:-80px;
    left:50%;
    width:180px;
    height:180px;
    background: radial-gradient(circle,#8ec5fc,#1f2a63);
    border-radius:50%;
    animation: rotateEarth 25s linear infinite;
}

@keyframes rotateEarth {
    from {transform:translateX(-50%) rotate(0)}
    to {transform:translateX(-50%) rotate(360deg)}
}

/* ===== SATELLITES ===== */
.satellite {
    position:fixed;
    width:10px;height:10px;
    background:white;
    border-radius:50%;
    box-shadow:0 0 10px #8ec5fc;
    animation: orbit 16s linear infinite;
}

.satellite1{top:15%;left:20%}
.satellite2{top:35%;left:75%;animation-delay:5s}
.satellite3{top:70%;left:30%;animation-delay:9s}

@keyframes orbit{
    0%{transform:translate(0,0)}
    50%{transform:translate(60px,-60px)}
    100%{transform:translate(0,0)}
}

/* ===== SHOOTING STARS ===== */
body::after{
    content:'';
    position:fixed;
    width:2px;height:2px;
    background:white;
    box-shadow:
      200px 100px #fff,
      400px 300px #fff,
      700px 200px #fff;
    animation:shooting 8s linear infinite;
}

@keyframes shooting{
    from{transform:translate(0,0)}
    to{transform:translate(-800px,800px)}
}

/* ===== PAGE LOAD ===== */
@keyframes pageLoad{
    from{opacity:0; transform:translateY(30px);}
    to{opacity:1; transform:translateY(0);}
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar{width:8px}
::-webkit-scrollbar-track{background:#070b24}
::-webkit-scrollbar-thumb{
    background:linear-gradient(#8ec5fc,#a18cd1);
    border-radius:10px;
}
/* =====================================================
   FIX LOGO ALIGNMENT (all courses same height)
   ===================================================== */
.project-logo{
    width: 70%;
    max-width: 280px;
    height: 180px;          /* forces same height */
    object-fit: cover;      /* keeps image ratio */
    margin-top: 15px;
    border-radius: 12px;
    transition: transform .5s;
}

/* =====================================================
   PDF POPUP MODAL (for Course 3)
/* =========================
   PDF MODAL FIXED VERSION
========================= */

.pdf-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(6px);
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* ================= PDF MODAL ================= */
