/* mtSoftAI - Premium CSS v1.3
   Fixed: Mobile Overhang & PC Menu Toggle Alignment
*/

:root {
    --bg-dark: #0b1220;
    --accent: #3b82f6;
    --glass: rgba(255, 255, 255, 0.05);
    --text-muted: rgba(255, 255, 255, 0.6);
}

* { 
    box-sizing: border-box; 
    margin: 0; 
    padding: 0; 
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-dark);
    color: #e6eef8;
    overflow-x: hidden;
    line-height: 1.6;
}

/* --- Fixed Topbar --- */
.topbar {
    height: 70px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5%;
    background: #111827;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 2000; /* টপবার সবার উপরে থাকবে */
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.logo { 
    font-size: 22px; 
    font-weight: 800; 
    color: var(--accent); 
    text-decoration: none; 
}

.menu-btn {
    width: 45px;
    height: 45px;
    background: var(--glass);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 12px;
    color: white;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    z-index: 2100; /* টপবারের চেয়েও উপরে যেন বাটনটা থাকে */
}

/* --- Content Offset --- */
main { 
    margin-top: 100px; 
}

/* --- Hero & Grid --- */
.hero { padding: 40px 20px; text-align: center; }
.title { 
    font-size: clamp(32px, 6vw, 56px); 
    font-weight: 800; 
    margin-bottom: 15px; 
    background: linear-gradient(to right, #fff, var(--accent)); 
    -webkit-background-clip: text; 
    -webkit-text-fill-color: transparent; 
}
.subtitle { color: var(--text-muted); font-size: 17px; max-width: 800px; margin: 0 auto; }

.grid-wrap { max-width: 1200px; margin: 20px auto 80px; padding: 0 20px; }
.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

.card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255,255,255,0.06);
    padding: 30px;
    border-radius: 18px;
    cursor: pointer;
    transition: 0.3s;
}
.card:hover { transform: translateY(-8px); border-color: var(--accent); background: rgba(59, 130, 246, 0.05); }
.card.special { border: 1px solid var(--accent); background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(107, 70, 193, 0.1)); }

.icon { font-size: 24px; color: var(--accent); margin-bottom: 20px; }
.card h3 { margin: 0; font-size: 20px; font-weight: 700; }
.card-desc { font-size: 13px; color: var(--text-muted); margin-top: 10px; }

/* --- Menu Drawer (FIXED) --- */
.menu-drawer {
    position: fixed;
    top: 70px;
    right: -100%; /* মোবাইলে পুরোপুরি স্ক্রিনের বাইরে থাকবে */
    width: 300px;
    height: calc(100vh - 70px);
    background: #111827;
    transition: 0.4s cubic-bezier(0.77, 0, 0.175, 1);
    z-index: 1500; /* টপবারের নিচে থাকবে */
    padding: 20px;
    box-shadow: -10px 10px 30px rgba(0,0,0,0.5);
    border-left: 1px solid rgba(255,255,255,0.05);
    overflow-y: auto;
    visibility: hidden; /* বন্ধ অবস্থায় যেন ক্লিক না পড়ে */
}

.menu-drawer.open {
    right: 0 !important;
    visibility: visible !important;
}

.menu-drawer h3 { color: var(--accent); margin: 10px 0 20px; font-size: 1.5rem; }
.menu-drawer ul { list-style: none; }
.menu-drawer li { 
    padding: 16px 0; 
    border-bottom: 1px solid rgba(255,255,255,0.05); 
    cursor: pointer; 
    transition: 0.2s;
}
.menu-drawer li:hover { color: var(--accent); padding-left: 8px; }

/* --- Detail Panel --- */
.detail-panel {
    position: fixed;
    inset: 0;
    background: rgba(7, 10, 18, 0.98);
    display: none;
    z-index: 3000;
    padding: 20px;
    align-items: center;
    justify-content: center;
}
.detail-card {
    background: #1a1f2b; 
    width: 100%; 
    max-width: 850px; 
    max-height: 85vh;
    overflow-y: auto; 
    border-radius: 20px; 
    padding: 35px;
    border: 1px solid rgba(255,255,255,0.1);
}

.close-panel-btn { 
    background: var(--glass); 
    padding: 10px 20px; 
    border-radius: 10px; 
    cursor: pointer; 
    display: inline-flex; 
    align-items: center; 
    gap: 10px; 
    margin-bottom: 25px; 
}

/* --- About & Footer --- */
.about { max-width: 1000px; margin: 60px auto; padding: 40px 20px; text-align: center; background: rgba(255,255,255,0.02); border-radius: 20px; }
footer { text-align: center; padding: 60px 20px; border-top: 1px solid rgba(255,255,255,0.05); color: var(--text-muted); }
footer a { color: var(--accent); text-decoration: none; }

.topic-badge { padding: 6px 12px; background: var(--glass); border-radius: 20px; font-size: 12px; margin: 4px; display: inline-block; color: var(--text-muted); }

/* --- Responsive Adjustments --- */
@media (max-width: 640px) {
    .menu-drawer { 
        width: 85%; /* মোবাইলে একটু জায়গা খালি রেখে আসবে */
    }
    .hero { padding: 40px 15px; }
}
/* Python File Links Styling */
.file-link {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6 !important;
    padding: 12px 15px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    transition: 0.3s;
    display: block;
}

.file-link:hover {
    background: #3b82f6;
    color: white !important;
    transform: translateX(5px);
}