/* =========================
   CONTAINER & PAGE LAYOUT
   ========================= */
.container {
    max-width: 1100px;
    margin: 30px auto;
    padding: 25px;
    background: #ffffffcd; /* slight transparency for modern look */
    backdrop-filter: blur(5px);
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.page-title {
    text-align: center;
    font-size: 2rem;
    color: #1a365d;
    margin-bottom: 10px;
    font-weight: 700;
}

.page-description {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.15rem;
    color: #4a5568;
    line-height: 1.6;
    text-align: left;
    border-bottom: 1px solid #ccc;
}

/* =========================
   GRID LAYOUT
   ========================= */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

/* =========================
   SCHEME CARD STYLING
   ========================= */
.scheme-card {
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: center;
}
.scheme-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.scheme-card h2 {
    font-size: 1.6rem;
    color: #2b6cb0;
    margin-bottom: 10px;
}
.scheme-card h3 {
    font-size: 1.2rem;
    margin-top: 10px;
    color: #2d3748;
}

.scheme-card p {
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
    margin-bottom: 20px;
}

/* =========================
   DOWNLOAD BUTTON
   ========================= */
.download-btn {
    display: inline-block;
    background: linear-gradient(45deg, #3182ce, #2b6cb0);
    color: #fff;
    padding: 12px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.download-btn:hover {
    background: linear-gradient(45deg, #2b6cb0, #2c5282);
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* =========================
   FOOTER
   ========================= */
footer {
    text-align: center;
    background: #1a202c;
    color: #cbd5e0;
    padding: 20px;
    margin-top: 50px;
    font-size: 0.95rem;
}

/* =========================
   AdSense WRAPPER
   ========================= */
.ads-wrapper {
    display: flex;
    justify-content: center;
    margin: 40px auto;
    width: 100%;
    border-top: 1px solid #ccc;
}
.ads-container {
    max-width: 100%;
    min-height: 90px;
    overflow: hidden;
    text-align: center;
}
.adsbygoogle {
    max-width: 100%;
}

/* =========================
   TABLE EXAMPLE
   ========================= */
  /* Scroll container */
.example-table-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    direction: ltl;              /* anza scroll upande wa kulia */

  /* hide scrollbar */
    scrollbar-width: none;       /* Firefox */
    -ms-overflow-style: none;    /* IE/Edge ya zamani */
}
.example-table-wrapper::-webkit-scrollbar {
    display: none;               /* Chrome, Safari, Opera */
}

/* Table yenyewe */
.example-table {
    width: 100%;
    border-collapse: collapse;
    direction: ltr;              /* maandishi yabaki kawaida */
    white-space: nowrap;         /* maneno yasijikunje */
    min-width: 700px;            /* kwenye screen <700px itabaki 700px na iwe scrollable */
    margin: 30px 0;
}

.example-table th,
.example-table td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: left;
}

.example-table th {
    background-color: #3182ce;
    color: #fff;
}
.horizontal-banner {
    background: #f0f4f8;
    padding: 20px;
}

.banner-content {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    flex-wrap: wrap;
}

.banner-content > div {
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    flex: 1 1 300px; /* responsive width */
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.banner-content h3 {
    margin-bottom: 15px;
    color: #3182ce;
    font-size: 1.2rem;
}

.banner-content ul {
    list-style: disc;
    padding-left: 20px;
}

.banner-content li {
    margin-bottom: 8px;
    font-size: 0.95rem;
}


/* =========================
   TIPS SECTION
   ========================= */
.tips-section ul {
    list-style: disc inside;
    margin-top: 15px;
    color: #2d3748;
}
.tips-section li {
    margin-bottom: 10px;
    line-height: 1.6;
}
a{
    text-decoration: none;
    outline: none;
    color: red;
    font-weight: bold;
}
.external-links {
    padding: 20px;
    background: #f9f9f9;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    margin: 20px 0;
}

.external-links h2 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    text-align: center;
    color: #333;
}

.content-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    flex-wrap: wrap; /* inasaidia kwenye skrini ndogo */
}

.exam-image {
    flex: 1 1 320px;
    max-width: 360px;
    text-align: center;
}

.exam-image img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

.exam-image figcaption {
    font-size: 0.9rem;
    color: #666;
    margin-top: 8px;
    text-align: left;
}

.links-text {
    flex: 2 1 200px;
}

.link-description {
    margin-bottom: 15px;
    font-size: 1rem;
    color: #444;
    text-align: left;
}

.resource-list {
    list-style: none;
    padding: 0;
}

.resource-list li {
    margin: 10px 0;
    text-align: left;
}

.resource-list a {
    font-weight: 600;
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;

}

.resource-list a:hover {
    color: #e67e22;
}

.small {
    font-size: 0.85rem;
    color: #777;
}
/* =========================
   RESPONSIVE DESIGN
   ========================= */
@media screen and (max-width: 768px) {
    .container {
        margin: 15px;
        padding: 20px;
    }
    .page-title { font-size: 1.5rem; }
    .page-description { font-size: 1rem; text-align: left; }
    .scheme-card h2 { font-size: 1.4rem; text-align: left; }
    .scheme-card h3 { font-size: 1rem; text-align: left; }
    .scheme-card p { font-size: 0.95rem; text-align: left; }
    .ads-wrapper { margin: 25px 0; }
    .content-wrapper {
        flex-direction: column;
        align-items: center;

    }
    p.firstNote{
        color: deeppink;
        font-weight: bold;
    }
    .links-text {
        text-align: center;
        margin-top: -60px;
    }
    #external-links-heading{
        text-align: left;
        color: block;
        font-weight: bold;
        font-size: 20px;
    }
}
@media (max-width: 700px) {
  .example-table table {
    min-width: 700px;   /* table ibaki na size hii */
    width: auto;        /* ruhusu scroll badala ya kupungua */
  }
  .example-table tr{
    width: 500px;
  }
  .exam-image {
        max-width: 600px; /* figure haitazidi 480px */
        margin: 0 auto;   /* center figure */
    }
    .links-text {
        text-align: center;
        margin-top: -30px;
    }
}
@media screen and (max-width: 480px) {
    .scheme-card h2 { font-size: 1.2rem; }
    .scheme-card h3 { font-size: 0.95rem; }
    .scheme-card p { font-size: 0.9rem; line-height: 1.5; }
    .download-btn { font-size: 13px; padding: 10px; width: 100%; text-align: center; }
    .page-title { font-size: 1.0rem; }
    .page-description { font-size: 0.95rem;}
    #external-links-heading{
        font-size: 18px;
    }
    .exam-image {
        max-width: 480px; /* figure haitazidi 480px */
        margin: 0 auto;   /* center figure */
    }

    .exam-image img {
        width: 100%;      /* picha i-refit ndani ya figure */
        height: auto;     /* isiharibike */
        display: block;   /* ionekane safi bila extra space */
        border-radius: 6px; /* optional - kona za mviringo */
    }
    .links-text {
        text-align: center;
        margin-top: -70px;
    }
   
}
@media screen and (max-width: 360px){
    .links-text {
        text-align: center;
        margin-top: -140px;
    }
    .exam-image figcaption {
        font-size: 0.7rem;
    }
}
