.collapsible {
    background-color: #28527a;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    margin-bottom: 1rem;
    width: 100%;
    text-align: left;
    transition: all 0.3s ease;
}

.collapsible:hover { background-color: #183e58; }

.content {
   /* display: none; */
    overflow: hidden;
    padding: 10px 20px;
    border-left: 3px solid #28527a;
    background-color: #f4f4f9;
    border-radius: 5px;
    margin-bottom: 1rem;
}

body.dark-mode .content { background-color: #333; }
body.dark-mode .collapsible { background-color: #666; }
body.dark-mode .collapsible:hover { background-color: #444; }

.typewriter-text {
    display: inline-block;
    overflow: hidden;
    white-space: nowrap;
    animation: typewriter 4s steps(30) infinite;
    font-size: 40px;
    text-align: center;
    position: relative;
    width: 0;
    margin: 0 auto;
    display: block;
    border-right: 2px solid black;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: Cambria, Cochin, Georgia, Times, "Times New Roman", serif;
    color: #2d2d2d;
    background: linear-gradient(120deg, #f0f4f8, #c8d9e6);
    line-height: 1.6;
}

body.dark-mode {
    color: #f0f4f8;
    background: linear-gradient(120deg, #2d2d2d, #1a1a1a);
}

header {
    text-align: center;
    padding: 1rem;
    background: linear-gradient(135deg, #6a9cde, #82c1e8);
    color: #fff;
    border-radius: 0 0 50px 50px;
    position: relative;
}

body.dark-mode header { background: linear-gradient(135deg, #1a1a1a, #333); }

header h1 { font-size: 2.5rem; }
header p { font-size: 1.2rem; margin-top: 1rem; }

nav {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
}

nav .nav-links { display: flex; align-items: center; gap: 1rem; }

nav a {
    text-decoration: none;
    color: #fff;
    padding: 0.5rem 1rem;
    background: #28527a;
    border-radius: 5px;
    transition: background 0.3s;
}

nav a:hover { background: #183e58; }

.hamburger { display: none; font-size: 2rem; cursor: pointer; color: #fff; }

main { padding: 1rem; }

.section, .block-section {
    display: none;
    margin-bottom: 2rem;
    background: #ffffff;
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.inner-section {
    background: none;
    box-shadow: none;
    padding: 0;
    margin-top: 2rem;
}

#about {
    display: block;
    background: linear-gradient(135deg, #82c1e8, #fff);
    color: #2d2d2d;
    text-align: justify;
}

.fullscreen-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.fullscreen-modal iframe { box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); }

.close-button {
    position: absolute;
    top: 20px;
    right: 20px;
    background-color: white;
    color: black;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    font-size: 18px;
    border-radius: 5px;
    z-index: 1001;
}

.close-button:hover { background-color: red; color: white; }

body.dark-mode .section, body.dark-mode .block-section {
    background: #333;
    box-shadow: 0 4px 8px rgba(255, 255, 255, 0.1);
}

body.dark-mode #about { background: linear-gradient(135deg, #333, #1a1a1a); color: #f0f4f8; }

#about p { margin-bottom: 1em; }

#skills h2 {
    text-align: left;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: #004aad;
}

#skills ul { list-style: square inside; padding: 0; margin: 0; }

#skills li {
    margin-bottom: 1rem;
    font-size: 1rem;
    color: #333;
    line-height: 0.6;
}

#skills li strong { color: #004aad; }

#skills h3 {
    text-align: left;
    font-size: 1.3rem;
    margin: 1.2rem 0 0.8rem;
    color: #004aad;
}

#skills h3:first-of-type { margin-top: 0; }

body.dark-mode #skills h2 { color: #529cff; }
body.dark-mode #skills h3 { color: #529cff; }
body.dark-mode #skills li strong { color: #529cff; }
body.dark-mode #skills li { color: #e4f1f6; }

#contact a { color: #28527a; text-decoration: none; }
body.dark-mode #contact a { color: #82c1e8; }

footer {
    text-align: center;
    padding: 1rem;
    background: #28527a;
    color: #fff;
    border-radius: 50px 50px 0 0;
}

body.dark-mode footer { background: #1a1a1a; }

.block-section::before {
    content: "";
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 5px;
    background: linear-gradient(90deg, #28527a, #6a9cde);
    border-radius: 10px;
}

.toggle-button {
    background-color: #004aad;
    color: white;
    border: none;
    padding: 6px 6px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.toggle-button:hover { background-color: #007bff; }
.toggle-button:active { background-color: #003d99; transform: scale(0.95); }

.toggle-dark-mode {
    position: fixed;
    top: 10px;
    right: 10px;
    background: #28527a;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    z-index: 1000;
}

.toggle-dark-mode:hover { background: #183e58; }
body.dark-mode .toggle-dark-mode { background: #666; }
body.dark-mode .toggle-dark-mode:hover { background: #444; }

.social-links {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 20px 0;
}

.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    border-radius: 10%;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.social-links a img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: #003d99;
}

.social-links a:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

body.dark-mode .social-links a { box-shadow: 0 2px 4px rgba(255, 255, 255, 0.1); }
body.dark-mode .social-links a:hover { box-shadow: 0 4px 8px rgba(255, 255, 255, 0.3); }

@media (max-width: 768px) {
    body { font-size: 1em; margin: 0; overflow-x: hidden; }
    
    header { width: 100%; flex-direction: column; padding: 1.5rem; text-align: center; }
    header h1 { font-size: 20px; }
    header p { font-size: 1rem; }
    header img { width: 100px; height: 100px; }
    
    nav { flex-direction: column; align-items: center; gap: 0.5rem; }
    nav .hamburger { font-size: 2rem; display: block; }
    nav .nav-links { display: none; flex-direction: column; width: 100%; text-align: center; }
    nav .nav-links.active { display: flex; }
    nav a { font-size: 1rem; padding: 0.8rem 0; width: 100%; }
    
    main { padding: 1rem; }
    section { padding: 1rem; margin-bottom: 1rem; border-radius: 10px; }
    .collapsible { font-size: 14px; padding: 8px 16px; }
    .content { padding: 8px 16px; }
    #skills { padding: 15px; max-width: 100%; }
    #skills h2 { font-size: 1.5rem; }
    #skills li { font-size: 0.9rem; line-height: 1.1; }
    
    .social-links { flex-wrap: wrap; justify-content: center; gap: 10px; }
    .social-links a { width: 40px; height: 40px; }
    
    #contact { text-align: center; }
    #contact a { font-size: 1rem; display: block; margin: 0.5rem 0; }
    
    footer { padding: 1rem; text-align: center; font-size: 0.9rem; }
    .toggle-dark-mode { font-size: 15px; padding: 5px 0px; }
}

.projects-list {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    padding-top: 1rem
}

.project-btn {
    background-color: #1e3a8a;
    color: rgb(168, 202, 233);
    border: none;
    padding: 15px;
    border-radius: 5px;
    width: 80%;
    max-width: 500px;
    cursor: pointer;
    font-size: 18px;
    text-align: center;
    transition: background-color 0.3s ease;
    padding-top: 1rem
}

.project-btn:hover { background-color: #3b82f6; }

.fullscreen-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8); /* Semi-transparent black background */
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 990px;
    width: 100%;
    min-height: 500px; /* Set a minimum height */
    background-color: rgb(64, 57, 57);
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    gap: 20px;
}


.images-column {
    display: flex;
    flex-direction: column; /* Stack images vertically */
    align-items: center;
    gap: 10px; /* Space between images */
    flex: 1; /* Take equal space */
}

.modal-image {
    max-width: 500px; /* Set a reasonable width */
    height: auto;
    border-radius: 8px;
}

.modal-text {
    flex: 1; /* Take equal space as images */
    text-align: left; /* Align text to the left */
    color: white;
}

.certificates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding-top: 2rem
}

.certificate-card {
    display: flex; /* Use flexbox for layout */
    flex-direction: column; /* Stack items vertically */
    align-items: center; /* Center items horizontally */
    justify-content: flex-start; /* Align items to the top */
    text-align: center; /* Center text */
    padding: 15px;
    border: 2px solid #1e3a8a;
    border-radius: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background-color: rgb(238, 219, 219); /* Set a solid background color */
    opacity: 1; /* Ensure full opacity */
    margin-bottom: 20px; /* Add space between cards */
}

.certificate-card img {
    width: 100%; /* Make the image take the full width of the card */
    height: auto; /* Maintain the aspect ratio */
    max-height: 250px; /* Set a maximum height to prevent images from being too large */
    object-fit: cover; /* Ensure the image covers the area without distortion */
    border-radius: 3px; /* Optional: add some rounding to the corners */
    margin-bottom: 10px; /* Add space below the image */
}

.certificate-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(86, 176, 232, 0.425);
}

.certificate-card h3 {
    color: #1e3a8a;
    font-size: 18px;
    margin-bottom: 10px;
}

.certificate-card p {
    color: #0a0a0a;
    font-size: 16px;
    line-height: 1.6;
}
