* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Poppins', sans-serif; line-height: 1.6; color: #333; }

/* NAVBAR */
.navbar { 
    background: linear-gradient(135deg, #0f3460, #1a5f7a); 
    padding: 1rem 0; 
    position: fixed; 
      align-items: center; 
    width: 100%; 
    top: 0; 
    z-index: 1000; 
}

.nav-container { 
    max-width: 80%; 
    margin: 0 auto; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    padding: 0 2rem; 
}

.logo { 
    color: #fff; 
    font-size: 1.5rem; 
    font-weight: 700; 
}

.nav-menu { 
    display: flex; 
    list-style: none; 
    gap: 2rem; 
}

.nav-menu a { 
    color: #fff; 
    text-decoration: none; 
    transition: color 0.3s; 
}

.nav-menu a:hover { 
    color: #4ecdc4; 
}

.hamburger { 
    display: none; 
    flex-direction: column; 
    cursor: pointer; 
}

.hamburger span { 
    width: 25px; 
    height: 3px; 
    background: #fff; 
    margin: 3px 0; 
    transition: 0.3s; 
}

/* HERO SECTION */
.hero { 
    background: linear-gradient(rgba(15,52,96,0.9), rgba(26,95,122,0.9)), url('hero-bg.jpg'); 
    height: 100vh; 
    display: flex; 
    flex-direction: column; 
    justify-content: center; 
    align-items: center; 
    text-align: center; 
    color: #fff; 
    padding: 0 2rem; 
    margin-top: 70px; 
}

.hero h2 { 
    font-size: 3rem; 
    margin-bottom: 1rem; 
}

.hero p { 
    font-size: 1.2rem; 
}

/* MAIN SECTION STYLE */
.section { 
    padding: 1.5rem 1.5rem; 
    max-width: 1200px; 
    margin: 0 auto; 
}

.section h2 { 
    font-size: 2.3rem; 
    text-align: center; 
    margin-bottom: 1.2rem; 
    color: #0f3460; 
}

.dark { 
    background: #f8f9fa; 
}

/* FEATURES GRID */
.features, .protocol-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 2rem; 
}

.feature-card, .protocol-item { 
    background: #fff; 
    padding: 2rem; 
    border-radius: 10px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.1); 
    text-align: center; 
    transition: transform 0.3s; 
}

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

.feature-card i { 
    font-size: 3rem; 
    color: #4ecdc4; 
    margin-bottom: 1rem; 
}

/* FOOTER */
footer { 
    background: #0f3460; 
    color: #fff; 
    text-align: center; 
    padding: 2rem; 
}

/* MOBILE RESPONSIVE */
@media (max-width: 768px) {
    .hamburger { display: flex; }

    .nav-menu { 
        position: fixed; 
        left: -100%; 
        top: 70px; 
        flex-direction: column; 
        background: #0f3460; 
        width: 100%; 
        text-align: center; 
        transition: 0.3s; 
        padding: 2rem 0; 
    }

    .nav-menu.active { left: 0; }

    .hero h2 { font-size: 2rem; }
}

/* SINGLE INFO BOX */
.single-info-box { 
    max-width: 1900px; 
    margin: 0 auto 4rem; 
}

/* TEXT + IMAGE CONTAINER */
.text-image-container {
    background: transparent;
    padding:10px 0;
    border-radius: 0;
    box-shadow: none;
    border:none;
    display: flex;
    gap: 30px;
    align-items: center;
    transition: all 0.4s ease;
    max-width: 1100px;
    margin: 0 auto;
}

/* IMAGE BOX */
.image-box {
    flex-shrink: 0;
    width: 280px;
}

.stm32-image {
    width: 100%;
    height: auto;
    max-width: 550px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transition: all 0.4s ease;
    display: block;
}

/* FEATURE LIST */
.feature-list {
    list-style: none;
    text-align: left;
    max-width: 500px;
    margin: 2rem auto 0;
}

.feature-list li {
    padding: 0.8rem 0;
    font-size: 1.1rem;
    position: relative;
    padding-left: 2rem;
}

.feature-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #4ecdc4;
    font-weight: bold;
    font-size: 1.2rem;
}

/* --------- NEW SECTION ADDED FOR TUTORIAL GRID --------- */

.tutorial-title {
    margin-top: 40px;
    text-align: center;
    color: #0f3460;
}

.tutorial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.tutorial-box {
    border: 1px solid #ddd;
    background: #fff;
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}

.box-header {
    background: #0f3460;
    color: white;
    text-align: center;
    padding: 10px;
    font-weight: bold;
    margin-bottom: 10px;
    border-radius: 5px;
}

.tutorial-box ul {
    list-style-type: none;
    padding-left: 10px;
}

.tutorial-box ul li {
    padding: 6px 0;
    border-bottom: 1px solid #eee;
    font-size: 14px;
}

.tutorial-box ul li:last-child {
    border-bottom: none;
}

/* -------- END OF NEW STYLES -------- */
/* TWO BOX GRID FOR KIT INFO */
.kit-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.kit-box {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9ff 100%);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.12);
    border: 1px solid rgba(78,205,196,0.2);
    transition: all 0.3s ease;
}

.kit-box:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 60px rgba(0,0,0,0.18);
}

.kit-box h3 {
    color: #0f3460;
    margin-bottom: 15px;
    font-size: 1.5rem;
    text-align: center;
}

.kit-box p {
    margin-bottom: 12px;
    font-size: 1rem;
    color: #444;
}

/* COMPONENT LIST STYLE */
.component-list {
    list-style: none;
    padding-left: 10px;
}

.component-list li {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
    font-size: 15px;
    position: relative;
    padding-left: 25px;
}

.component-list li::before {
    content: '⚙';
    position: absolute;
    left: 0;
    color: #4ecdc4;
}
/* ===== OVERVIEW SECTION LAYOUT ===== */

.overview-container {
    display: flex;
    gap: 30px;
    align-items: center;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9ff 100%);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.12);
    border: 1px solid rgba(78,205,196,0.2);
    margin-bottom: 40px;
}

.overview-text {
    flex: 1;
}

.overview-text h3 {
    color: #0f3460;
    margin-bottom: 15px;
}

.overview-image {
    flex: 1;
    text-align: center;
}

.overview-image img {
    width: 100%;
    max-width: 350px;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}



/* ===== COMPONENT LIST GRID ===== */

.components-section {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9ff 100%);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.12);
    border: 1px solid rgba(78,205,196,0.2);
    margin-bottom: 40px;
}

.components-section h3 {
    text-align: center;
    color: #0f3460;
    margin-bottom: 20px;
}

.component-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
}

.component-item {
    background: #fff;
    padding: 12px;
    text-align: center;
    border-radius: 10px;
    border: 1px solid #eee;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    font-size: 15px;
    transition: 0.3s;
}

.component-item:hover {
    background: #0f3460;
    color: white;
    transform: translateY(-5px);
}



/* ===== RESPONSIVE ===== */

@media (max-width: 768px) {

    .overview-container {
        flex-direction: column;
        text-align: center;
    }

    .overview-image img {
        max-width: 250px;
    }
}
.component-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.component-card {
    background: white;
    border-radius: 12px;
    border: 1px solid #ddd;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    text-align: center;
    padding: 15px;
    transition: 0.3s ease;
}

.component-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.component-card img {
    width: 100%;
    max-width: 140px;
    margin: 0 auto 12px;
}

.component-card h4 {
    color: #0f3460;
    margin: 8px 0;
}

.component-card p {
    font-size: 14px;
    color: #444;
}
.projects-container {
    padding: 30px;
    background-color: #f5f7fb;
}

.projects-container h2 {
    text-align: center;
    margin-bottom: 25px;
    color: #0d2f5a;
}

.project-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 10px;
}

.project-card {
    background: white;
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    box-shadow: 0px 0px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0px 0px 20px rgba(0,0,0,0.2);
}

.project-card img {
    width: 150px;
    height: 120px;
    object-fit: contain;
    margin-bottom: 10px;
}

.project-card h4 {
    color: #0d2f5a;
    margin-bottom: 8px;
}

.project-card p {
    font-size: 14px;
    color: #555;
}
.toggle-title {
    cursor: pointer;
    text-align: center;
    color: #0d2f5a;
    margin-top: 20px;
}

.projects-container {
    padding: 20px;
    background-color: #f5f7fb;
    border-radius: 10px;
    margin-top: 10px;
}

.project-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.project-card {
    background: white;
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    box-shadow: 0px 0px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0px 0px 20px rgba(0,0,0,0.2);
}

.project-card img {
    width: 150px;
    height: 120px;
    object-fit: contain;
}
.projects-container {
    margin: 20px;
    padding: 10px;
}

.project-cards {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.project-card {
    background: white;
    border-radius: 10px;
    padding: 10px;
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 0 20px rgba(0,0,0,0.2);
}

.project-card img {
    width: 100%;
    height: 140px;
    border-radius: 8px;
}

.toggle-title {
    cursor: pointer;
    background: #173663;
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    width: 180px;

    /* CENTER ALIGN CODE */
    margin: 20px auto;
    text-align: center;
    display: block;

    font-size: 20px;
    font-weight: bold;
    transition: 0.3s;
}




/* RESPONSIVE DESIGN */

@media (max-width: 1200px) {
    .project-cards {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .project-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .project-cards {
        grid-template-columns: repeat(1, 1fr);
    }
}
/* ===== Code Block Styling ===== */

.code-block {
    background-color: #0d1117;        /* Black theme */
    color: #00ff9f;                   /* Hacker green text */
    padding: 15px;
    border-radius: 8px;
    font-family: Consolas, monospace;
    font-size: 14px;

    max-height: 350px;                /* Fixed height */
    overflow-y: auto;                 /* Vertical scroll */
    overflow-x: auto;                 /* Horizontal scroll */

    border: 2px solid #00bcd4;
    white-space: pre;                 /* Maintain formatting */
    margin-top: 10px;
    margin-bottom: 20px;

    box-shadow: 0 0 10px rgba(0,0,0,0.4);
}

/* Scrollbar styling */
.code-block::-webkit-scrollbar {
    width: 8px;
}

.code-block::-webkit-scrollbar-thumb {
    background: #00bcd4;
    border-radius: 10px;
}
/* Text left – Image right layout */

.flex-image-text {
    display: flex;
    align-items: stretch;       /* Make both sides equal height */
    gap: 20px;
    margin-top: 20px;
}

.flex-text {
    flex: 1;
    text-align: justify;
}

.flex-image {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-image img {
    width: 100%;
    height: auto;
    max-height: 100%;          /* Adjust to text height */
    object-fit: contain;
    border: 3px solid #0d6efd;
    border-radius: 10px;
    padding: 5px;
    background: white;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .flex-image-text {
        flex-direction: column;
    }
}
.text-image-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    flex-wrap: wrap;
}


.image-box {
    width: 45%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.image-box img {
   width: 100%;
    height: auto;
    max-height: 320px;
    object-fit: contain;
}


.info-text {
    width: 50%;
}
@media (max-width: 768px) {
    .text-image-container {
        flex-direction: column;
    }

    .info-text,
    .image-box {
        width: 100%;
    }

    .image-box img {
        max-height: 400px;
    }
}
.zoomable:hover {
    transform: scale(1.05);
    transition: 0.3s ease-in-out;
    cursor: zoom-in;
}
/* CLICKABLE IMAGE EFFECT */
.zoomable {
    cursor: zoom-in;
    transition: 0.3s;
}

.zoomable:hover {
    transform: scale(1.03);
}

/* MODAL BACKGROUND */
.image-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.9);
    text-align: center;
}

/* MODAL IMAGE */
.modal-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90%;
    border-radius: 10px;
    box-shadow: 0 0 25px rgba(255,255,255,0.2);
}

/* CLOSE BUTTON (MINIMIZE) */
.close-btn {
    position: absolute;
    top: 15px;
    right: 25px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    background: rgba(0,0,0,0.6);
    padding: 5px 15px;
    border-radius: 8px;
}

.code-container {
    background: #0e0e0e;
    color: #ffffff;
    padding: 15px;
    border-radius: 10px;
    max-height: 500px;
    overflow-x: auto;
    overflow-y: auto;
    margin-top: 10px;
    font-family: Consolas, "Courier New", monospace;
}

.code-container pre {
    margin: 0;
    white-space: pre;
    text-align: left;
}

.code-container code {
    display: block;
    white-space: pre;
    line-height: 1.5;
    font-size: 15px;
}
.download-box-container {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
}

.download-box {
    display: inline-block;
    background-color: #0d6efd;
    color: white;
    padding: 14px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    text-align: center;
    min-width: 150px;
    transition: 0.3s ease;
    box-shadow: 0 3px 6px rgba(0,0,0,0.2);
}

.download-box:hover {
    background-color: #084298;
    transform: translateY(-3px);
}
.horizontal-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #ffffff;
    padding: 15px;
    margin-top: 15px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    border-left: 5px solid #dadada;
}

.content-area {
    width: 55%;
}

.image-area {
    width: 40%;
    text-align: right;
}

.image-area img {
    width: 90%;
    max-height: 220px;
    border: 1px solid #ccc;
    border-radius: 8px;
}

.arrow-label {
    display: block;
    margin-top: 5px;
    font-weight: bold;
    color: #0b3d91;
}

/* Mobile Responsive */
@media(max-width:768px) {
    .horizontal-box {
        flex-direction: column;
        text-align: center;
    }

    .content-area, .image-area {
        width: 100%;
    }

    .image-area {
        margin-top: 10px;
    }
}

/* ===== GENERAL BODY STYLE ===== */
body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.8;
    background-color: #f5f7fa;
    color: #333;
}

/* ===== MAIN CONTAINER ===== */
.container {
    width: 90%;
    max-width: 1100px;
    margin: auto;
    padding: 15px 0;
}

/* ===== HEADINGS ===== */
h1 {
    text-align: center;
    margin-bottom: 40px;
    color: #f8f9fc;
}

h2 {
    margin-top: 40px;
    margin-bottom: 15px;
    color: #0d6efd;
    
    padding-left: 10px;
}

h3 {
    margin-top: 25px;
    margin-bottom: 10px;
}

/* ===== PARAGRAPH ===== */
p {
    margin-bottom: 15px;
}

/* ===== LIST STYLE ===== */
ul {
    padding-left: 20px;
}

li {
    margin-bottom: 8px;
}

/* ===== IMAGE STYLE ===== */
img {
    width: 100%;
    max-width: 700px;
    display: block;
    /*margin: 20px auto;*/
    border-radius: 8px;
}

/* ===== SECTION SPACING ===== */
/* .section {
    margin-bottom: 60px;
} */

/* ===== CODE BLOCK STYLE ===== */
pre {
    background-color: #1e1e1e;
    color: #ffffff;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
}

code {
    font-family: Consolas, monospace;
}
/* ===== PROJECT NAVIGATION ===== */

.navigation{
    display:flex;
    justify-content:space-between;
    align-items:center;
    max-width:1000px;
    margin:50px auto;
    padding:0 20px;
}

/* Navigation Buttons */

.btn-primary{
    text-decoration:none;
    background:#173663;
    color:#fff;
    padding:10px 20px;
    border-radius:5px;
    font-size:15px;
    font-weight:500;
    transition:0.3s;
}

/* Hover Effect */

.btn-primary:hover{
    background:#281a7c;
}
/* ================= FOOTER ================= */

.main-footer{
    background:#173663;
    color:#ffffff;
    padding-top:50px;
    font-family:'Poppins', sans-serif;
}

/* Footer Container */
.footer-container{
    width:90%;
    margin:auto;
    display:flex;
    justify-content:space-between;
    gap:40px;
    flex-wrap:wrap;
}

/* Footer Boxes */
.footer-box{
    flex:1;
    min-width:250px;
}

/* Footer Logo */
.footer-logo{
    width:70px;
    margin-bottom:10px;
}

/* Heading */
.footer-box h3{
    margin-bottom:15px;
    font-size:20px;
    font-weight:600;
}

/* Paragraph Text */
.footer-box p{
    color:#d9e3f0;
    line-height:1.7;
    font-size:14px;
}

/* Footer Links */
.footer-links{
    list-style:none;
    padding:0;
}

.footer-links li{
    margin-bottom:10px;
}

.footer-links a{
    text-decoration:none;
    color:#d9e3f0;
    font-size:14px;
    transition:0.3s;
}

.footer-links a:hover{
    color:#ffffff;
    padding-left:5px;
}

/* Social Icons */
.social-icons{
    margin-top:10px;
}

.social-icons i{
    margin-right:15px;
    font-size:18px;
    cursor:pointer;
    color:white;
    transition:0.3s;
}

.social-icons i:hover{
    color:#66a3ff;
}

/* Bottom Copyright */
.footer-bottom{
    text-align:center;
    padding:18px;
    border-top:1px solid rgba(255,255,255,0.2);
    margin-top:35px;
    font-size:14px;
    color:#cfd8e6;
}

/* ================= RESPONSIVE ================= */

@media (max-width:768px){

.footer-container{
    flex-direction:column;
    text-align:center;
}

.footer-box{
    margin-bottom:30px;
}

.social-icons{
    justify-content:center;
}

}


