/* Fonts */
:root {
    --default-font: "Kanit",  system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    --heading-font: "Kanit",  sans-serif;
    --nav-font: "Kanit",  sans-serif;
}

/* Global Colors - The following color variables are used throughout the website. Updating them here will change the color scheme of the entire website */
:root {
    --background-color: #000000; /* Changed to black */
    --default-color: #ffffff; /* Changed to white */
    --heading-color: #ffffff; /* Changed to white */
    --accent-color: #29afff; /* Accent color that represents your brand on the website. It's used for buttons, links, and other elements that need to stand out */
    --surface-color: #000000; /* Changed to black */
    --contrast-color: #ffffff; /* Changed to white */
}

/* Nav Menu Colors - The following color variables are used specifically for the navigation menu. They are separate from the global colors to allow for more customization options */
:root {
    --nav-color: #5b5b5b;  /* The default color of the main navmenu links */
    --nav-hover-color: #000000; /* Applied to main navmenu links when they are hovered over or active */
    --nav-mobile-background-color: #f5f5f5; /* Used as the background color for mobile navigation menu */
    --nav-dropdown-background-color: #ffffff; /* Used as the background color for dropdown items that appear when hovering over primary navigation items */
    --nav-dropdown-color: #5b5b5b; /* Used for navigation links of the dropdown items in the navigation menu. */
    --nav-dropdown-hover-color: #000000; /* Similar to --nav-hover-color, this color is applied to dropdown navigation links when they are hovered over. */
}

/* Color Presets - These classes override global colors when applied to any section or element, providing reuse of the sam color scheme. */

.dark-background {
    --background-color: #000000;
    --default-color: #ffffff;
    --heading-color: #ffffff;
    --surface-color: #000000;
    --contrast-color: #ffffff;
}

/* Smooth scroll */
:root {
    scroll-behavior: smooth;
}

.header-social-links {
    display: flex;
}
/*on hover make it text come out of image transition */
.header-social-links a {
    color: #fff;
    transition: color 0.3s ease, transform 0.3s ease;
}

.header-social-links a:hover {
    color: #f0f0f0;
    transform: scale(1.1);
}
@media (max-width: 768px) {
    .resume-text {
        display: none;
    }
}
/*--------------------------------------------------------------
# General Styling & Shared Classes
--------------------------------------------------------------*/
body {
    color: var(--default-color); /* Remains white */
    background-color: var(--color-dark); /* This should also be updated */
    font-family: var(--default-font);
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: 0.3s;
}

a:hover {
    color: color-mix(in srgb, var(--accent-color), transparent 25%);
    text-decoration: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--heading-color);
    font-family: var(--heading-font);
}

/* PHP Email Form Messages
------------------------------*/
.php-email-form .error-message {
    display: none;
    background: #df1529;
    color: #ffffff;
    text-align: left;
    padding: 15px;
    margin-bottom: 24px;
    font-weight: 600;
}

.php-email-form .sent-message {
    display: none;
    color: #ffffff;
    background: #059652;
    text-align: center;
    padding: 15px;
    margin-bottom: 24px;
    font-weight: 600;
}

.php-email-form .loading {
    display: none;
    background: var(--surface-color);
    text-align: center;
    padding: 15px;
    margin-bottom: 24px;
}

.php-email-form .loading:before {
    content: "";
    display: inline-block;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    margin: 0 10px -6px 0;
    border: 3px solid var(--accent-color);
    border-top-color: var(--surface-color);
    animation: php-email-form-loading 1s linear infinite;
}

@keyframes php-email-form-loading {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/*--------------------------------------------------------------
# Global Header
--------------------------------------------------------------*/
.header {
    color: var(--default-color);
    background-color: var(--background-color);
    padding: 15px 0;
    transition: all 0.5s;
    z-index: 997;
}

.header .logo {
    line-height: 1;
}

.header .logo img {
    max-height: 32px;
    margin-right: 8px;
    background-color: #000000; /* Added to ensure no transparency */
}

.header .logo h1 {
    font-size: 30px;
    margin: 0;
    font-weight: 700;
    color: var(--heading-color);
}

/*--------------------------------------------------------------
# Global Footer
--------------------------------------------------------------*/
.footer {
    color: var(--default-color);
    background-color: var(--background-color); /* This should also be updated */
    font-size: 14px;
    padding: 40px 0;
    position: relative;
}

.footer .copyright p {
    margin-bottom: 0;
}

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

.footer .social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid color-mix(in srgb, var(--default-color), transparent 50%);
    font-size: 16px;
    color: color-mix(in srgb, var(--default-color), transparent 50%);
    margin: 0 5px;
    transition: 0.3s;
}

.footer .social-links a:hover {
    color: var(--accent-color);
    border-color: var(--accent-color);
}

.footer .credits {
    margin-top: 10px;
    font-size: 13px;
    text-align: center;
}

/*--------------------------------------------------------------
# Preloader
--------------------------------------------------------------*/
#preloader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    overflow: hidden;
    background-color: var(--background-color);
    transition: all 0.6s ease-out;
}

#preloader:before {
    content: "";
    position: fixed;
    top: calc(50% - 30px);
    left: calc(50% - 30px);
    border: 6px solid var(--accent-color);
    border-top-color: color-mix(in srgb, var(--accent-color), transparent 90%);
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: animate-preloader 1s linear infinite;
}

@keyframes animate-preloader {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/*--------------------------------------------------------------
# Scroll Top Button
--------------------------------------------------------------*/
.scroll-top {
    position: fixed;
    visibility: hidden;
    opacity: 0;
    right: 15px;
    bottom: -15px;
    z-index: 99999;
    width: 44px;
    height: 44px;
    border-radius: 50px;
    transition: all 0.4s;
}

.scroll-top i {
    font-size: 24px;
    color: white;
    line-height: 0;
}

.scroll-top:hover {
    background-color: #000000; /* Changed to black */
    color: var(--contrast-color);
}

.scroll-top.active {
    visibility: visible;
    opacity: 1;
    bottom: 15px;
}

/*--------------------------------------------------------------
# Disable aos animation delay on mobile devices
--------------------------------------------------------------*/
@media screen and (max-width: 768px) {
    [data-aos-delay] {
        transition-delay: 0s !important;
    }
}

/*--------------------------------------------------------------
# Global Page Titles & Breadcrumbs
--------------------------------------------------------------*/
.page-title {
    color: var(--default-color);
    background-color: var(--background-color);
    padding-top: 120px;
    text-align: center;
    position: relative;
}

.page-title h1 {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 10px;
}

.page-title .breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    justify-content: center;
    padding: 0;
    margin: 0;
    font-size: 16px;
    font-weight: 400;
}

.page-title .breadcrumbs ol li+li {
    padding-left: 10px;
}

.page-title .breadcrumbs ol li+li::before {
    content: "/";
    display: inline-block;
    padding-right: 10px;
    color: color-mix(in srgb, var(--default-color), transparent 70%);
}

/*--------------------------------------------------------------
# Global Sections
--------------------------------------------------------------*/
section,
.section {
    color: var(--default-color);
    background-color: var(--background-color);
    padding: 60px 0;
    scroll-margin-top: 90px;
    overflow: clip;
}

@media (max-width: 1199px) {

    section,
    .section {
        scroll-margin-top: 66px;
    }
}

/*--------------------------------------------------------------
# Global Section Titles
--------------------------------------------------------------*/
.section-title {
    text-align: center;
    padding-bottom: 60px;
    position: relative;
}

.section-title h2 {
    font-size: 32px;
    font-weight: 400;
    margin-bottom: 15px;
}

.section-title p {
    margin-bottom: 0;
}

/*--------------------------------------------------------------
# Portfolio Section
--------------------------------------------------------------*/
.portfolio .portfolio-info h3 {
    font-size: 24px;
    margin-bottom: 5px;
}

.portfolio .portfolio-info p {
    font-size: 15px;
}

.portfolio .portfolio-filters {
    padding: 0;
    margin: 0 auto 20px auto;
    list-style: none;
}

.portfolio .portfolio-filters li {
    cursor: pointer;
    display: inline-block;
    padding: 0;
    font-size: 16px;
    font-weight: 400;
    margin: 0 10px;
    line-height: 1;
    margin-bottom: 5px;
    transition: all 0.3s ease;
}

.portfolio .portfolio-filters li:hover{
    color: #29afff;
    transform: scale(1.1);
}
.portfolio .portfolio-filters li.filter-active {
    border-bottom: 3px solid var(--accent-color);
    padding-bottom: 3px;

}

.portfolio .portfolio-filters li:first-child {
    margin-left: 0;
}

.portfolio .portfolio-filters li:last-child {
    margin-right: 5px;
}

@media (max-width: 575px) {
    .portfolio .portfolio-filters li {
        font-size: 14px;
        margin: 0 5px;
    }
}

.portfolio .portfolio-content {
    position: relative;
    overflow: hidden;
}

.portfolio .portfolio-content img {
    transition: 0.4s;
}


.portfolio .portfolio-content:hover img {
    transform: scale(1.1);
}

/*--------------------------------------------------------------
# Portfolio Details Section
--------------------------------------------------------------*/
.portfolio-details .portfolio-details-slider img {
    width: 100%;
}

.portfolio-details .portfolio-details-slider .swiper-pagination {
    margin-top: 20px;
    position: relative;
}

.portfolio-details .portfolio-details-slider .swiper-pagination .swiper-pagination-bullet {
    width: 12px;
    height: 12px;
    background-color: color-mix(in srgb, var(--default-color), transparent 85%);
    opacity: 1;
}

.portfolio-details .portfolio-details-slider .swiper-pagination .swiper-pagination-bullet-active {
    background-color: var(--accent-color);
}

.portfolio-details .portfolio-info {
    background-color: var(--surface-color);
    padding: 30px;
    box-shadow: 0px 0 30px rgba(0, 0, 0, 0.1);
}

.portfolio-details .portfolio-info h3 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid color-mix(in srgb, var(--default-color), transparent 85%);
}

.portfolio-details .portfolio-info ul {
    list-style: none;
    padding: 0;
    font-size: 15px;
}

.portfolio-details .portfolio-info ul li+li {
    margin-top: 10px;
}

.portfolio-details .portfolio-description {
    padding-top: 30px;
}

.portfolio-details .portfolio-description h2 {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 20px;
}

.portfolio-details .portfolio-description p {
    padding: 0;
    color: color-mix(in srgb, var(--default-color), transparent 30%);
}

/*--------------------------------------------------------------
# Service Details Section
--------------------------------------------------------------*/
.service-details .services-list {
    background-color: var(--surface-color);
    padding: 10px 30px;
    border: 1px solid color-mix(in srgb, var(--default-color), transparent 90%);
    margin-bottom: 20px;
}

.service-details .services-list a {
    display: block;
    line-height: 1;
    padding: 8px 0 8px 15px;
    border-left: 3px solid color-mix(in srgb, var(--default-color), transparent 70%);
    margin: 20px 0;
    color: color-mix(in srgb, var(--default-color), transparent 20%);
    transition: 0.3s;
}

.service-details .services-list a.active {
    color: var(--heading-color);
    font-weight: 700;
    border-color: var(--accent-color);
}

.service-details .services-list a:hover {
    border-color: var(--accent-color);
}

.service-details .services-img {
    margin-bottom: 20px;
}

.service-details h3 {
    font-size: 26px;
    font-weight: 700;
}

.service-details h4 {
    font-size: 20px;
    font-weight: 700;
}

.service-details p {
    font-size: 15px;
}

.service-details ul {
    list-style: none;
    padding: 0;
    font-size: 15px;
}

.service-details ul li {
    padding: 5px 0;
    display: flex;
    align-items: center;
}

.service-details ul i {
    font-size: 20px;
    margin-right: 8px;
    color: var(--accent-color);
}



/*--------------------------------------------------------------
# Contact Section
--------------------------------------------------------------*/
.contact {
    background-image: url("../img/contact-bg.png"); /* This should also be updated */
    background-color: #000000; /* Added to ensure background is black */
    background-position: left center;
    background-repeat: no-repeat;
    position: relative;
}

@media (max-width: 640px) {
    .contact {
        background-position: center 50px;
        background-size: contain;
    }
}

.contact:before {
    content: "";
    background: #000000; /* Changed to black */
    position: absolute;
    bottom: 0;
    top: 0;
    left: 0;
    right: 0;
}

.contact .info-item+.info-item {
    margin-top: 40px;
}

.contact .info-item i {
    background: var(--accent-color);
    color: var(--contrast-color);
    font-size: 20px;
    width: 44px;
    height: 44px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50px;
    transition: all 0.3s ease-in-out;
    margin-right: 15px;
}

.contact .info-item h3 {
    padding: 0;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 5px;
}

.contact .info-item p {
    padding: 0;
    margin-bottom: 0;
    font-size: 14px;
}

.contact .php-email-form {
    height: 100%;
}

.contact .php-email-form input[type=text],
.contact .php-email-form input[type=email],
.contact .php-email-form textarea {
    font-size: 14px;
    padding: 10px 15px;
    box-shadow: none;
    border-radius: 0;
    color: var(--default-color);
    background-color: #000000; /* Changed to black */
    border-color: #000000; /* Changed to black */
}

.contact .php-email-form input[type=text]:focus,
.contact .php-email-form input[type=email]:focus,
.contact .php-email-form textarea:focus {
    border-color: var(--accent-color);
}

.contact .php-email-form input[type=text]::placeholder,
.contact .php-email-form input[type=email]::placeholder,
.contact .php-email-form textarea::placeholder {
    color: color-mix(in srgb, var(--default-color), transparent 70%);
}

.contact .php-email-form button[type=submit] {
    color: var(--contrast-color);
    background: var(--accent-color);
    border: 0;
    padding: 10px 30px;
    transition: 0.4s;
    border-radius: 50px;
}

.contact .php-email-form button[type=submit]:hover {
    background: color-mix(in srgb, var(--accent-color), transparent 20%);
}



/*--------------------------------------------------------------
# Toggle Dark/Light Theme
--------------------------------------------------------------*/
/* The switch container */
.switch {
    --transition: 300ms;
    --transition500: 500ms;
    --color-dark: #000000;
    --color-darkGray: #000000;
    --color-gray: #52555a;
    --color-offwhite: #cecece;
    --shadow-color: var(--color-dark);
    position: relative;
    display: flex;
    align-items: center;
    width: 60px;
    height: fit-content;
    background-color: var(--color-dark);
    border-radius: 30px;
    padding: 4px;
    transition: var(--transition500);
    user-select: none;
    cursor: pointer;
    overflow: hidden;
}

/* Svg styles */
.switch .svg {
    transition: var(--transition);
    position: absolute;
    left: 5px;
}
.switch .moon {
    width: 18px;
    fill: var(--color-gray);
    opacity: 1;
}

.switch .sun {
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    border-radius: 50%;
    left: calc(100% - 21.5px);
    top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    scale: 0.8;
    opacity: 0;
}

.switch .sun .dot {
    position: relative;
    display: block;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--color-dark);
    background: white;
    z-index: 1;
    box-shadow: 11px 0px 0px var(--shadow-color),
    10.3px 0px 0px var(--shadow-color), -11px 0px 0px var(--shadow-color),
    -10.3px 0px 0px var(--shadow-color), 0px -11px 0px var(--shadow-color),
    0px -10.3px 0px var(--shadow-color), 0px 11px 0px var(--shadow-color),
    0px 10.3px 0px var(--shadow-color), 8px 8px 0px var(--shadow-color),
    7.3px 7.3px 0px var(--shadow-color), 8px -8px 0px var(--shadow-color),
    7.3px -7.3px 0px var(--shadow-color), -8px -8px 0px var(--shadow-color),
    -7.3px -7.3px 0px var(--shadow-color), -8px 8px 0px var(--shadow-color),
    -7.3px 7.3px 0px var(--shadow-color);
}

.switch .sun .dot::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: white;
    border: 2px solid var(--color-dark);
}

/*checkbox styles */
.switch .circle {
    appearance: none;
    position: relative;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    left: 0;
    background-color: var(--color-darkGray);
    border: 1px solid var(--color-darkGray);
    transition: var(--transition500);
    box-shadow: 1px 1px 20px 3px var(--color-darkGray);
}

.switch:has(.circle:checked) {
    background: var(--color-offwhite);
}

.switch .circle:hover {
    margin-left: 3px;
}
.switch .circle:checked:hover {
    margin-left: -3px;
}

.switch .circle:checked {
    left: calc(100% - 24px);
    background: white;
    border-color: white;
    box-shadow: 1px 1px 30px 12px white;
}

.switch:has(.circle:checked) > .sun {
    opacity: 1;
}

.switch:has(.circle:checked) > .moon {
    opacity: 0;
}

body {
    background-color: var(--color-dark); /* This should also be updated */
    color: var(--default-color);
    transition: background-color 0.3s, color 0.3s;
}


/*--------------------------------------------------------------
# Dark Mode Social Media Icons
 */

.header-social-links a {
    margin: 0 10px;
    color: #333; /* Light mode color */
    font-size: 24px; /* Adjust size as needed */
}

/* Dark mode styles */
body.dark-background .header-social-links a {
    color: #fff; /* Change to white or another light color */
}

/* Optional: Change icon color on hover */
.header-social-links a:hover {
    color: #29afff; /* Change to accent color on hover */
}

body.dark-background .header-social-links a:hover {
    color: #29afff; /* Change hover color in dark mode */
}


html, body {
    height: 100%; /* Ensure full height */
    margin: 0; /* Remove default margin */
}

.main {
    min-height: 100vh; /* Ensure main section covers full viewport height */
    background-color: #000000; /* Set background to black */
}

.portfolio {
    position: relative; /* Ensure proper positioning */
    overflow: hidden; /* Prevent overflow */
}

.isotope-container {
    height: auto; /* Allow height to adjust automatically */
}

/* Horizontal bar style */
.portfolio-content .horizontal-bar {
    width: 100%;
    height: 4px; /* Adjust height as needed */
    background-color: var(--accent-color); /* Use your accent color */
    margin-top: 10px; /* Space between image and bar */
}

/* Add this new class for rounded images */
.rounded-image {
    border-radius: 15px; /* Adjust the value as needed */
}


/*_________________________________*/
/* Title bar container at the bottom of portfolio images */
.portfolio .portfolio-content {
    position: relative;
    overflow: hidden;
    border-radius: 8px; /* Maintain rounded corners */
}

/* Title bar styling */
.portfolio .portfolio-content .title-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.8); /* Semi-transparent black background */
    padding: 10px 15px;
    transform: translateY(0); /* Always visible */
}

/* Title text styling */
.portfolio .portfolio-content .title-bar h4 {
    color: #ffffff;
    margin: 0;
    font-size: 14px;
    font-weight: 500;
}

/* Adjust existing hover effect to work with title bar */
.portfolio .portfolio-content .portfolio-info {
    bottom: 3px; /* Leave space for title bar */
}

.portfolio-info h1{
    font-size: 70px;
}

.portfolio-filters {
    display: flex;
    justify-content: center; /* center horizontally */
    gap: 20px;              /* spacing between items */
    padding: 0;
    margin: 0 auto;         /* make sure it sits in center */
    list-style: none;
}

.portfolio-filters li,
.portfolio-filters a {
    cursor: pointer;
    font-size: 18px;
    font-weight: 500;
    transition: all 0.3s ease;
}
