:root {
    /* Main colours */
    --primary-color: #333;    /* Bright Blue */
    --primary-text-color:#fff;
    --secondary-color: #50E3C2;    /* Mint Green */
    --accent-color: #F5A623;    /* Vibrant Orange */
    --background-color: #eef1ec;    /* Light Gray Background */
    --foreground-color: #212121;    /* Dark Gray Text */
    --border-color: #E0E0E0;    /* Soft Gray Borders */
    --error-color: #D0021B;    /* Bright Red */
    --success-color: #7ED321;    /* Bright Green */

    /* utility */
    --hover-color: var(--foreground-color);
    --active-color: var(--accent-color);
    --hover-background-color: rgba(0, 0, 0, 0.3);    /* Semi-transparent hover background */
    --active-background-color: rgba(0, 0, 0, 0.1);    /* Semi-transparent active background */
    --hover-border-color: rgba(0, 0, 0, 0.3);    /* Semi-transparent hover border */
    --active-border-color: rgba(0, 0, 0, 0.5);    /* Semi-transparent active border */
    --transition-speed: 0.3s;    /* Transition speed for smooth effects */

    /* sizes */
    --header-height: 100px;
    --link-width: 140px;
    --link-height: 40px;
    --main-width: 1400px;
}

* {
    margin: 0px;
    padding: 0px;
    box-sizing: border-box;
}

body,
html {
    width: 100%;    /* 100% of the viewport width */
    height: 100vh;    /* 100% of the viewport height */
    font-family: 'Roboto', Arial, sans-serif;
    line-height: 1.6;
}

body{
    display: flex;
    flex-direction: column;
    align-items: center;
}

main{
    flex: 1;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    background-color: var(--background-color);
    margin-top: var(--header-height);
}

.standard-width {
    width: 100%;
    max-width: var(--main-width);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}


a {
    color: var(--primary-text-color);
    text-decoration: none;
    padding: 10px;
}

a:hover{
    text-decoration: underline;
}

/* Paragraphs */
p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 15px;
    color: var(--foreground-color);
}

/* Heading 1 */
h1 {
    font-size: 30px;
    color: var(--foreground-color);
}

h1 i {
    color: green;
}

/* Heading 2 */
h2 {
    font-size: 22px;
    color: var(--foreground-color);
    margin-bottom: 10px;
}

h2 i{
    color: orange;
}

/* Heading 3 */
h3 {
    font-size: 18px;
    color: var(--foreground-color);
}


/* effects for reactive button like elements */
.reactive {
    color: var(--foreground-color);
    background-color: rgba(0, 0, 0, 0.0);
    border: 1px solid rgba(0, 0, 0, 0.0);
    padding: 9px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color var(--transition-speed),
        color var(--transition-speed),
        border-color var(--transition-speed),
        transform var(--transition-speed);
    cursor: pointer;
}

.reactive:hover {
    color: var(--hover-color);
    background-color: var(--hover-background-color);
    border-color: var(--hover-border-color);
    transform: translateY(-2px);
}

.reactive:active {
    color: var(--active-color);
    background-color: var(--active-background-color);
    border-color: var(--active-border-color);
    transform: translateY(1px);
}


.button {
    color: var(--foreground-color);
    background-color: var(--accent-color);
    border: 1px solid rgba(0, 0, 0, 0.5);
    padding: 9px;
    border-radius: 5px;
    cursor: pointer;
    transition: var(--transition-speed);
    margin: 10px;
}

.button:hover {
    transform: scale(1.1);
}

.button:active {
    transform: translateY(1px);
}


/*********************************************************************************************************************/
/*************************************          Header styles           **********************************************/
/*********************************************************************************************************************/
 header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    display: flex;
    flex-shrink: 0;
    flex-direction: column;
    z-index: 1000;
 }

 /* Flexbox for rows */
 .top-bar {
    display: flex;
    flex-grow: 1;
    background-color: white;
 }

 .bottom-bar {
    display: flex;
    height: var(--link-height);
    background-color: var(--primary-color);
 }

 .top-bar>div,
 .bottom-bar>div {
    height: 100%;
    display: flex;
    align-items: center;
 }



 /* Left and Right Content: Fixed width to fit content */
 .left-content,
 .right-content {
     flex-shrink: 0;
     text-align: center;
     color: var(--foreground-color);
 }

 /* Middle Content: Expands to fill available space and spreads items evenly */
 .middle-content {
     display: flex;
     justify-content: space-evenly;
     flex-grow: 1;
 }

 /* Middle Content Items Styling */
 .middle-content span {
     background-color: var(--accent-color);
     color: var(--foreground-color);
     border-radius: 4px;
     border: 1px solid var(--border-color);
     text-align: center;
 }

.logo{
    width: 70px;
    height: 50px;
    padding: 5px;
}

/*********************************************************************************************************************/
/*************************************          Tab-link styles         **********************************************/
/*********************************************************************************************************************/
.tab-link {
    height: 100%;
    width: 120px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.tab-link:hover,
.tab-link.active {
    background-color: var(--secondary-color);
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 100vw;
    z-index: 10;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(3px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: var(--header-height);
}

.hide {
    display: none !important;
}

.close-btn {
    position: absolute;
    top: 5px;
    right: 5px;
    font: 30px sans-serif;
}

.content {
    background: #ffffff;
    border-radius: 10px;
    width: 100%;
    max-width: var(--main-width);
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    max-height: 2000px;
    transition: var(--transition-speed);
}
.content.minimise {
    max-height: 0px;
}

.head-section {
    background-color: #f4f4f4;
    padding: 20px;
    border-bottom: 1px solid #ddd;
    text-align: center;
    position: relative;
}

.body-section{
    padding: 10px;
}

.body-section>ul {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    /* Increased minimum width */
    gap: 1.5rem;
    /* Adjusted gap for better spacing */
    list-style: none;
}

.body-section>ul>li {
    display: flex;
    /* Enable Flexbox for the skill card */
    flex-direction: column;
    /* Arrange content vertically */
    justify-content: space-between;
    /* Push content to the top and bottom */
    background: #f9f9f9;
    padding: 1.5rem;
    border: 1px solid #ddd;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    text-align: left;
    border-radius: 8px;
    box-sizing: border-box;
    height: 100%;
    /* Ensure consistent card height */
}

.body-section>ul>li p {
    margin: 0 0 10px;
    /* Add spacing between paragraphs */
}

.body-section>ul>li .tags {
    margin-top: auto;
    /* Push tags to the bottom */
    font-size: 0.9em;
    color: #666;
    /* Slightly muted text color */
}



/*********************************************************************************************************************/
/*************************************          Main Nav styles         **********************************************/
/*********************************************************************************************************************/
/* constructed hamburger icon hidden by default */
.hamburger-icon {
    width: 50px;
    height: 44px;
    margin-left: 2px;
    display: none;
    flex-direction: column;
    justify-content: space-between;
}

.hamburger-icon:hover div {
    background-color: var(--hover-color);
}

.hamburger-icon:active div {
    background-color: var(--active-color);
}

.bar1,
.bar2,
.bar3 {
    width: 100%;
    height: 4px;
    background-color: var(--foreground-color);
    border-radius: 2px;
    transition: var(--transition-speed);;
}

.change .bar1 {
    transform: translate(0, 10px) rotate(-45deg);
}

.change .bar2 {
    opacity: 0;
}

.change .bar3 {
    transform: translate(0, -10px) rotate(45deg);
}

/* Nav link styles */
.main-nav {
    height: 100%;
}

.main-nav ul {
    height: 100%;
    list-style-type: none;
    display: flex;
}

.main-nav li {
    height: 100%;
}

.main-nav a {
    height: 100%;
    min-width: var(--link-width);
    display: flex;
    justify-content: center;
    align-items: center;
}

.main-nav li:hover a {
    background-color: var(--accent-color);
}

.main-nav li:hover ul a {
    background-color: var(--secondary-color);
}

.main-nav li:hover, ul a:hover {
    background-color: var(--accent-color);
}

.main-nav li ul {
    display: none;
}

.main-nav li a:hover+ul,
.main-nav li ul:hover {
    display: block !important;
}

/* Show vertical nav */
.main-nav.active {
    height: var(--link-height);
    display: flex !important;
    position: absolute;
    top: var(--header-height);
    left: 0;
    flex-direction: column;
    z-index: 1000;
}

.main-nav.active>ul {
    display: block;
}

.main-nav.active>ul li {
    position: relative;
}

.main-nav.active>ul li a {
    background-color: var(--secondary-color);
}

.main-nav.active ul li ul {
    position: absolute;
    left: 100%;
    top: 0;
}

.main-nav.active ul li ul a{
    background-color: var(--primary-color);
}


/* compress links into hamburger when they no longer fit in horrisontal space */
@media (max-width: 600px) {
    .main-nav {
        display: none;
    }

    .hamburger-icon {
        display: flex;
    }
}

/*********************************************************************************************************************/
/*************************************          home styles           **********************************************/
/*********************************************************************************************************************/

.home h1{
    margin-top: 40px;
    margin-bottom: 10px;
    font-size: 50px;
}

.image-wrapper {
    width: 300px;
    height: 300px;
    margin: 30px 0;
    position: relative;    /* Allows absolute positioning of the image */
    overflow: hidden;    /* Ensures the image doesn't get squished */
    transition: var(--transition-speed);    /* Smoothly transition the height */
}
.contract{
    height: 0px;
    margin: 0px;
}

.contract img{
    opacity: 0px;
}

.theme-image {
    opacity: 1;
    width: 100%;
    height: 300px;
    position: absolute;
    top: 0;
    left: 0;
    background-image: var(--image-src);
    background-size: cover;
    transition: var(--transition-speed);
}

/*********************************************************************************************************************/
/*************************************          skill-card styles           **********************************************/
/*********************************************************************************************************************/

.skills-container {
    display: flex;
    visibility: hidden;
    flex-wrap: wrap;
    justify-content: space-around;
    align-items: center;
    gap: 20px;
    transition: opacity var(--transition-speed), transform var(--transition-speed), visibility var(--transition-speed);
    opacity: 0;
    transform: translateY(30px);
    margin-bottom: 30px;
    margin-top: 20px;
}

.skills-container.show {
    visibility: visible;
    opacity: 1;
    transform: translateY(0px);
}

.skill-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 150px;
    height: 150px;
    padding: 20px;
    background-color: var(--foreground-color);
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: transform var(--transition-speed), background-color var(--transition-speed);
}

.skill-card:hover {
    transform: scale(1.1);
    background-color: var(--secondary-color);
    cursor: pointer;
}

.skill-card.selected{
    background-color: var(--secondary-color);
}

.skill-card i {
    font-size: 36px;
    color: var(--accent-color);
    margin-bottom: 10px;
}

.skill-card h2 {
    font-size: 16px;
    color: var(--primary-text-color);
}

li.clickable:hover{
    background-color: var(--secondary-color);
    cursor: pointer;
}
li.clickable.selected {
    background-color: var(--secondary-color);
}

.skill-details {
    display: flex;
    gap: 5px;
    margin: 10px, 0px;
    align-items: flex-start;
}

.skill-details .column {
    flex: 1;
    text-align: left;
    margin-bottom: 20px;
}

.skill-details .column ul {
    list-style: disc;
    /* Use bullet points */
    padding-left: 20px;
    /* Indent for neatness */
    margin: 0;
    /* Remove extra spacing */
}

.skill-details .column p {
    font-weight: bold;
    margin-bottom: 8px;
    /* Slightly more space between title and list */
}
/*********************************************************************************************************************/
/*************************************          acordion styles           **********************************************/
/*********************************************************************************************************************/
.accordion {
    border: 5px solid #ccc;
    border-radius: 5px;
    width: 100%;
    /* margin: auto; */
}

.accordion-item {
    border-bottom: 1px solid #ccc;
}

.accordion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #f4f4f4;
    cursor: pointer;
    padding: 15px;
    text-align: left;
    font-size: 16px;
    font-weight: bold;
    border: none;
    outline: none;
    width: 100%;
    transition: background-color 0.3s;
}

.accordion-header:hover {
    background-color: #e0e0e0;
}

.accordion-header span {
    display: flex;
    align-items: center;
    gap: 10px;
}

.accordion-header .icon {
    font-size: 20px;
}

.accordion-header .arrow {
    margin-left: auto;
    font-size: 16px;
    transition: transform 0.3s;
}

.accordion-header.active .arrow {
    transform: rotate(90deg);
}

.accordion-content {
    background-color: #ffffff;
    font-size: 14px;
    overflow: hidden;
    transition: max-height var(--transition-speed) ease-out;
    max-height: 0px;
}

/*********************************************************************************************************************/
/*************************************          example styles           **********************************************/
/*********************************************************************************************************************/

#article-display
{
    margin-top: 30px;
    width: 100%;
}

/* Section Styling */
.section {
    margin-bottom: 2rem;
}

.section h2 {
    font-size: 1.8rem;
    color: #ff6f61;
    margin-bottom: 0.5rem;
    border-bottom: 2px solid #ff6f61;
    padding-bottom: 0.25rem;
}

.section p {
    font-size: 1rem;
    color: #cfcfcf;
    margin: 0.5rem 0 1rem;
}

/* Code Block Styling */
pre {
    background-color: #2b2b3d;
    color: #c3e88d;
    padding: 1rem;
    border-radius: 6px;
    overflow-x: auto;
    font-size: 0.9rem;
    line-height: 1.5;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.5);
    margin-bottom: 1rem;
}

code {
    font-family: 'Fira Code', monospace;
    white-space: pre-wrap;
    word-wrap: break-word;
    display: block;
}





/*********************************************************************************************************************/
/*************************************          about styles           **********************************************/
/*********************************************************************************************************************/

.about-container {
    display: flex;
    gap: 2rem;    /* Adds space between the two columns */
    align-items: flex-start;    /* Align items to the top */
}

.about-content {
    flex: 2;    /* Takes up more space for text content */
}

.about-image {
    flex: 1;    /* Takes up less space for the image */
    display: flex;
    justify-content: center;
    /* Center the image horizontally */
    align-items: center;
    /* Center the image vertically */
}

.about-image img {
    max-width: 100%;
    /* Ensures the image does not overflow */
    height: auto;
    /* Maintains aspect ratio */
    border-radius: 10px;
    /* Adds rounded corners */
}

@media (max-width: 768px) {
    .about-container {
        flex-direction: column;        /* Stacks the columns vertically on smaller screens */
    }

    .about-image {
        order: 2;
    }

    .about-content {
        order: 1;
    }

}

/*********************************************************************************************************************/
/*************************************          contact styles           **********************************************/
/*********************************************************************************************************************/
.contact-wrapper {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 50px;
}

.contact-form {
    flex: 1 1 45%;
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.contact-form .form-group {
    margin-bottom: 15px;
}

.contact-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 14px;
    box-sizing: border-box;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 5px var(--secondary-color);
}

.contact-form .submit-btn {
    background: var(--secondary-color);
    color: var(--foreground-color);
    padding: 10px 15px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.contact-form .submit-btn:hover {
    background: var(--accent-color);
}

.contact-info {
    flex: 1 1 45%;
    text-align: left;
}

.contact-info h2 {
    font-size: 24px;
    margin-bottom: 15px;
}

.contact-info a {
    color: var(--secondary-color);
    text-decoration: none;
}

.contact-info a:hover {
    text-decoration: underline;
}

.social-links {
    margin-top: 20px;
}

.social-links a {
    font-size: 24px;
    color: var(--foreground-color);
    margin-right: 15px;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--secondary-color);
}


/*********************************************************************************************************************/
/*************************************          Footer styles           **********************************************/
/*********************************************************************************************************************/
footer {
    width: 100%;
    height: var(--link-height);
    color: var(--primary-text-color);
    background-color: var(--primary-color);
    display: flex;
    justify-content: center;
    align-items: center;
}

footer p{
    color: var(--primary-text-color);
}