/* Root variables for color scheme and accent color */
:root {
    color-scheme: light dark;
    --accent-color: #3ddc84; /* Dark mode accent color */
    --accent-color-dark: #1c7a46; /* Dark mode dark accent color */
}

/* Use media query to define light mode colors */
@media (prefers-color-scheme: light) {
    :root {
        --accent-color: #2ea463; /* Light mode accent color */
        --accent-color-dark: #134d2d; /* Light mode dark accent color */
    }
}

/* General body styles */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background-color: light-dark(#fff, #121212);
  color: light-dark(#444, #fff);
}

/* Header styles */
header {
  background-color: light-dark(rgba(255, 255, 255, 0.3), rgba(18, 18, 18, 0.3));
  color: light-dark(#444, #fff);
  padding: 0.5rem 0;
  text-align: center;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid light-dark(rgba(0, 0, 0, 0.1), rgba(255, 255, 255, 0.2));
  transition: height 0.3s ease;
}

/* Styles for the logo image in the header */
header ul.left img {
  height: 40px;
  transition: height 0.3s ease;
}

/* Align logo and text horizontally */
header ul.left li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Flex styling for the a tag inside the header */
header ul.left li a {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Styles for the header when it's in the "small" state (e.g., when scrolling down) */
header.small-header {
  height: 45px;
  transition: height 0.3s ease;
}

header.small-header ul.left img {
  height: 20px;
  transition: height 0.3s ease;
}

/* Navigation styles */
nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  align-items: center;
}

nav ul.left {
  margin-left: 1rem;
}

nav ul.right {
  margin-right: 1rem;
  display: flex;
  gap: 1rem;
}

nav ul li {
  display: inline;
}

/* Navigation link styles */
nav ul li a {
  color: light-dark(#444, #fff);
  text-decoration: none;
  transition: transform 0.3s ease, color 0.3s ease;
  display: inline-block;
}

nav ul li a i {
  font-size: 0.9em;
  transition: transform 0.3s ease;
}

header ul.left li:hover p,
nav ul li a:hover,
nav ul li p:hover {
  transform: scale(1.1);
  color: var(--accent-color);
  transition: transform 0.3s ease, color 0.3s ease;
}

/* Main content styles */
main {
  margin-top: 80px;
  padding: 0;
}
#main-page {
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  color: light-dark(#fff, #fff);
  text-align: left;
  position: relative;
  margin-top: -80px;
}

#main-page h2 {
  font-size: 5rem;
  font-weight: bold;
  margin: 0.5rem 0;
  padding-left: 18%;
}

#main-page p {
  font-size: 1.8rem;
  margin: 0.5rem 0;
  padding-left: 18%;
}

#main-page p a,
i {
  font-size: 1.6rem;
}

a {
  color: inherit;
  text-decoration: none;
}

/* Background image styles for the main page */
#main-page img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
  opacity: 0.7;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 70%, rgba(0, 0, 0, 0));
  filter: brightness(50%);
}

#role {
  text-decoration-color: var(--accent-color);
}

/* Accent color style */
.accent {
  color: var(--accent-color);
}

/* Styles for the section below the main content */
#below-main {
  padding: 2rem 10%;
  margin: 2rem 0;
  align-items: center;
}

/* Section title styles */
.section-title {
  color: var(--accent-color);
  text-align: center;
  padding: 2rem 0;
  font-size: 2rem;
}

/* About section styles */
#about {
  margin-bottom: 4rem;
}

/* Skills section styles */
#skills {
  position: relative;
  width: 100%;
  overflow: hidden;
  margin-bottom: 4rem;
}

#skills h2 {
  color: light-dark(#000, #fff);
  font-size: 2.5rem;
}

/* Experience section styles */
#experience {
  margin-bottom: 10rem;
  padding-top: 6rem;
  padding-bottom: 3rem;
}

/* Interests section styles */
#interests {
  margin-bottom: 4rem;
  padding-bottom: 4rem;
}

/* Certifications section styles */
#certifications {
  margin-bottom: 4rem; /* Increased bottom margin */
  padding-bottom: 4rem; /* Increased padding */
}

/* Projects section styles */
#projects {
  padding: 2rem 0; /* Increased padding */
  background-color: light-dark(#fff, #121212);
  margin-bottom: 4rem; /* Increased bottom margin */
}

/* Quote section styles */
.quote {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding: 3rem; /* Increased padding */
  background-color: light-dark(#f4f4f4, rgba(0, 0, 0, 0.7));
  border-radius: 10px;
  margin: 4rem 0; /* Increased margin */
  color: light-dark(#000, #fff);
}

/* Skills section styles */
#skills {
  position: relative;
  width: 100%;
  overflow: hidden;
}

#skills h2 {
  color: light-dark(#000, #fff);
  font-size: 2rem;
}

#skills ul {
  list-style: none;
  padding: 0;
}

#skills ul li {
  background-color: light-dark(#ebebeb, #333);
  color: light-dark(#333, #fff);
  padding: 0.5rem;
  margin: 0.5rem 0;
  border-radius: 5px;
}

/* Matrix background styles */
#skills #matrixBackground {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  padding: 0;
  background-color: light-dark(#fff, #000);
  overflow: hidden;
  font-family: monospace;
  font-size: 20px;
  color: light-dark(green, lime);
  pointer-events: none;
}

.matrix-column {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.matrix-char {
  opacity: 0.1;
  transition: opacity 0.5s;
}

/* Styles for content on top of the matrix background */
#skills #on-top-of-matrix {
  position: relative;
  z-index: 2;
  color: light-dark(#000, #fff);
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Skill panes styles */
.skill-panes {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
}

.skill-pane {
  flex: 1;
  background-color: light-dark(rgba(255, 255, 255, 0.5), rgba(0, 0, 0, 0.5));
  padding: 1rem;
  border-radius: 8px;
}

.skill-pane h3 {
  text-align: center;
  margin-bottom: 1rem;
}

.skill-pane ul {
  list-style: none;
  padding: 0;
  text-align: center;
}

.skill-pane ul li {
  background-color: light-dark(#333, #333);
  color: light-dark(#fff, #fff);
  padding: 0.5rem;
  margin: 0.5rem 0;
  border-radius: 5px;
  display: inline-block;
}

/* Certification panes styles */
.certification-panes {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.certification-pane {
  flex: 1;
  background-color: light-dark(rgba(233, 233, 233, 0.5), rgba(0, 0, 0, 0.5));
  padding: 1rem;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.certification-pane h3 {
  text-align: center;
  margin: -0.4rem 0;
  padding: 5px 0;
}

.certification-pane ul {
  list-style: none;
  padding: 0;
  text-align: center;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
}

.certification-pane ul li {
  background-color: light-dark(#f4f4f4, #333);
  color: light-dark(#444, #fff);
  padding: 0.5rem;
  margin: 0.5rem 0;
  border-radius: 5px;
  flex-grow: 1;
  width: 97%;
}

.certification-pane ul li strong {
  color: var(--accent-color);
}

.certification-pane ul li a {
  color: light-dark(#000, #fff);
  text-decoration: underline;
  text-decoration-color: var(--accent-color);
}

/* Certifications header styles */
.certifications-header {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}

.certifications-header h2 {
  margin: 0;
}

.certifications-header p {
  margin: 0;
  font-size: 1.2rem;
}

.certifications-subtitle {
  text-align: center;
  font-size: 1.2rem;
  margin-top: -3rem;
}

/* Job styles */
.job {
  margin-bottom: 2rem;
}

.job h3 {
  margin: 0;
}

.job p {
  margin: 0.5rem 0;
}

.job ul {
  list-style: disc;
  padding-left: 1.5rem;
}

/* Footer styles */
footer {
  background-color: light-dark(#fff, #333);
  color: light-dark(#444, #fff);
  text-align: center;
  padding: 0.5rem 0;
  width: 100%;
  font-size: 0.8rem;
  border-top: 1px solid light-dark(#ddd, #444);
  box-shadow: light-dark(0 -2px 4px rgba(0, 0, 0, 0.1), 0 -2px 4px rgba(255, 255, 255, 0.1));
  position: relative; /* Change from absolute/fixed positioning */
  bottom: auto; /* Remove bottom positioning */
  margin-top: 2rem; /* Add margin to separate from content */
}

footer table {
  width: 100%;
  height: 50px;
  table-layout: fixed;
}

footer table td {
  text-align: center;
  vertical-align: middle;
}

footer table td a {
  color: light-dark(#000, #fff);
  transition: color 0.3s ease;
}

footer table td a:hover {
  color: var(--accent-color);
}

/* Scroll-to-top button styles */
.scroll-top {
  position: fixed;
  visibility: hidden;
  opacity: 0;
  right: 15px;
  bottom: -15px;
  z-index: 99999;
  background-color: light-dark(var(--accent-color), var(--accent-color-dark));
  width: 44px;
  height: 44px;
  border-radius: 50%;
  transition: background 0.3s ease, transform 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.scroll-top.hidden {
  display: none;
}

.scroll-top i {
  font-size: 24px;
  color: light-dark(#000, #fff);
  line-height: 0;
}

.scroll-top:hover {
  background-color: light-dark(#134d2d, #145a32);
  transform: scale(1.1);
}

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

/* About text styles */
.about-text {
  font-size: 1.2rem;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.about-text .accent {
  color: var(--accent-color);
  font-weight: bold;
}

/* CV button container styles */
.cv-button-container {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

/* CV button styles */
.cv-button {
  display: inline-block;
  background-color: light-dark(var(--accent-color), var(--accent-color-dark));
  color: light-dark(#fff, #fff);
  padding: 10px 20px;
  border-radius: 50px;
  font-size: 1rem;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s ease, transform 0.3s ease;
  text-align: center;
}

.cv-button:hover {
  background-color: light-dark(#32b76c, #145a32);
  transform: scale(1.1);
}

/* Quote styles */
.quote {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding: 3rem; /* Increased padding */
  background-color: light-dark(#f4f4f4, rgba(0, 0, 0, 0.7));
  border-radius: 10px;
  margin: 4rem 0; /* Increased margin */
  color: light-dark(#000, #fff);
}

.quote blockquote {
  width: 100%;
  margin: 0;
}

.quote .quote-text {
  font-size: 1.7rem;
  line-height: 1.8;
  text-align: right;
  font-style: italic;
  color: var(--accent-color);
}

.quote .quote-author {
  margin-top: 1rem;
  font-size: 1.4rem;
  font-style: normal;
  text-align: left;
  color: light-dark(#000, #fff);
}

/* Animation container styles */
.animation-container {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  width: 100%;
  height: 50px;
  overflow: hidden;
  white-space: nowrap;
  margin-bottom: 1rem;
}

.emoji-man {
  font-size: 2rem;
  position: absolute;
  z-index: 1;
}

/* Moving background styles */
.moving-background {
  display: flex;
  animation: moveBackground 10s linear infinite;
}

.background-item {
  font-size: 2rem;
  margin-right: 2rem;
}

/* Keyframes for the moving background animation */
@keyframes moveBackground {
  0% {
    transform: translateX(100%);
  }
  100% {
    transform: translateX(-100%);
  }
}

/* Google search bar styles */
.google-search-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 20px 0;
}

.google-logo {
  height: 40px;
  margin-right: 10px;
}

.search-input {
  width: 60%;
  padding: 10px;
  font-size: 16px;
  border: 1px solid light-dark(#ddd, #333);
  border-radius: 24px;
  box-shadow: light-dark(0 2px 4px rgba(0, 0, 0, 0.1), 0 2px 4px rgba(255, 255, 255, 0.1));
  padding-left: 35px;
}

/* Search tabs styles */
.search-tabs {
  display: flex;
  justify-content: center;
  margin-bottom: 20px;
}

.tab {
  margin: 0 10px;
  padding: 10px 20px;
  font-size: 14px;
  color: light-dark(#555, #aaa);
  cursor: pointer;
}

.tab.active {
  color: light-dark(#000, #fff);
  border-bottom: 2px solid var(--accent-color);
}

/* Search results styles */
.search-results {
  margin: 20px 0;
  text-align: left;
  color: light-dark(#fff, #000);
}

.search-result {
  margin-bottom: 20px;
}

.result-title {
  font-size: 18px;
  color: var(--accent-color);
  margin-bottom: 5px;
}

.result-url {
  font-size: 14px;
  color: light-dark(#006621, #00a651);
}

.result-snippet,
.result-skills {
  font-size: 14px;
  color: light-dark(#444, #aaa);
}

.result-skills {
  color: light-dark(#888, #ccc);
}

/* Google mockup styles */
.google-mockup {
  text-align: center;
  margin-bottom: 20px;
}

.google-header {
  display: flex;
  justify-content: space-between;
  padding: 10px 20px;
}

.left-links a,
.right-links a {
  color: light-dark(#000, #fff);
  margin: 0 10px;
  text-decoration: none;
}

.google-logo {
  font-size: 2.5rem;
  font-weight: bold;
  color: var(--accent-color);
  margin: 20px 0;
}

/* Search bar styles */
.search-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 20px 0;
  position: relative;
  width: 100%;
}

.search-icon {
  font-size: 1.5rem;
  margin-right: 10px;
  position: absolute;
  left: 26%;
  top: 50%;
  transform: translateY(-50%);
  color: light-dark(#666, #999);
  z-index: 1;
}

.search-input {
  width: 50%;
  padding: 10px 20px 10px 40px;
  font-size: 16px;
  border: 1px solid light-dark(#ddd, #333);
  border-radius: 24px;
  box-shadow: light-dark(0 2px 4px rgba(0, 0, 0, 0.1), 0 2px 4px rgba(255, 255, 255, 0.1));
  margin-right: 10px;
}

/* Search and lucky button styles */
.search-button,
.lucky-button {
  padding: 10px 20px;
  font-size: 16px;
  border: none;
  border-radius: 24px;
  background-color: light-dark(var(--accent-color), var(--accent-color-dark));
  color: light-dark(#000, #fff);
  margin: 0 5px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.3s ease;
}

.search-button:hover,
.lucky-button:hover {
  background-color: light-dark(var(--accent-color), var(--accent-color-dark));
  transform: scale(1.1);
}

.location {
  color: rgb(128, 128, 128);
  margin-top: 10px;
}

/* Search results box styles */
.search-results-box {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10000;
  overflow-y: auto;
  background-color: light-dark(#fff, #2a2a2a); 
  color: light-dark(#000, #fff); 
  backdrop-filter: blur(5px);
  padding: 120px 10% 20px;
  max-width: 80%;
  margin: 0 auto;
}

/* Close button styles */
.close-button {
  position: absolute;
  top: 20px;
  right: 20px;
  background: light-dark(var(--accent-color), var(--accent-color-dark));
  color: light-dark(#000, #fff);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
  z-index: 10000;
}

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

/* Throbbing animation for search button */
.search-button.throbbing {
  animation: throb 1.5s infinite;
}

@keyframes throb {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

.search-tabs {
  display: flex;
  justify-content: center;
  margin-bottom: 20px;
}

.tab {
  margin: 0 10px;
  padding: 10px 20px;
  font-size: 14px;
  color: light-dark(#555, #aaa);
  cursor: pointer;
  position: relative;
}

.tab.active {
  color: light-dark(#000, #fff);
  border-bottom: 2px solid var(--accent-color);
}

.search-results {
  margin: 20px 0;
  text-align: left;
  color: light-dark(#000, #fff);
}

.search-result {
  margin-bottom: 20px;
}

.result-title {
  font-size: 18px;
  color: var(--accent-color);
  text-decoration: none;
  margin-bottom: 5px;
}

.result-title:hover {
  text-decoration: none;
}

.result-url {
  font-size: 14px;
  color: light-dark(#006621, #00a651);
}

.result-snippet,
.result-skills {
  font-size: 14px;
  color: light-dark(#444, #aaa);
}

.result-skills {
  color: light-dark(#888, #ccc);
}

.subheading {
  margin-left: 20px;
}

.subheading h4 {
  font-size: 16px;
  color: var(--accent-color);
  margin-bottom: 5px;
}

.google-mockup {
  text-align: center;
  margin-bottom: 20px;
}

.google-header {
  display: flex;
  justify-content: space-between;
  padding: 10px 20px;
}

.left-links a,
.right-links a {
  color: light-dark(#000, #fff);
  margin: 0 10px;
  text-decoration: none;
}

.google-logo {
  font-size: 2.5rem;
  font-weight: bold;
  color: var(--accent-color);
  margin: 20px 0;
  text-align: center;
  display: flex;
  justify-content: center;
}

.search-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 20px 0;
  position: relative;
  width: 100%;
}

.search-icon {
  font-size: 1.5rem;
  margin-right: 10px;
  position: absolute;
  left: 26%;
  top: 50%;
  transform: translateY(-50%);
  color: light-dark(#666, #999);
  z-index: 1;
}

.search-input {
  width: 50%;
  padding: 10px 20px 10px 40px;
  font-size: 16px;
  border: 1px solid light-dark(#ddd, #333);
  border-radius: 24px;
  box-shadow: light-dark(0 2px 4px rgba(0, 0, 0, 0.1), 0 2px 4px rgba(255, 255, 255, 0.1));
  margin-right: 10px;
}

.search-button,
.lucky-button {
  padding: 10px 20px;
  font-size: 16px;
  border: none;
  border-radius: 24px;
  background-color: light-dark(var(--accent-color), var(--accent-color-dark));
  color: light-dark(#000, #fff);
  margin: 0 5px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.3s ease;
}

.search-button:hover,
.lucky-button:hover {
  background-color: light-dark(#134d2d, #145a32);
  transform: scale(1.1);
}

.location {
  color: rgb(128, 128, 128);
  margin-top: 10px;
}

/* Styles for the search results box */
.search-results-box {
  display: none;
  background-color: light-dark(#fff, #0c0c0c);
  padding: 20px;
  border-radius: 0;
  overflow-y: auto;
  transition: all 0.3s ease-in-out;
  box-sizing: border-box;
  padding-top: 60px;
  color: light-dark(#000, #fff);
}

/* Styles for the close button */
.close-button {
  position: sticky;
  top: 10px;
  right: 1200px;
  background: light-dark(var(--accent-color), var(--accent-color-dark));
  color: light-dark(#fff, #000);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

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

/* Google mockup hover effect */
.google-header a:hover,
.location a:hover {
  color: var(--accent-color);
}

/* AI Overview Section */
.ai-overview {
  background-color: light-dark(#cecece, #3d3d3d); 
  padding: 20px;
  border-radius: 10px;
  margin-bottom: 20px;
  height: auto; /* Set height to auto to expand by default */
  position: relative;
  overflow: visible; /* Ensure content is visible */
}

/* Remove gradient overlay */
.ai-overview::after {
  display: none;
}

.ai-overview-title {
  font-size: 1.3rem;
  font-weight: bold;
  color: var(--accent-color);
  margin-bottom: 10px;
}

.ai-overview-summary {
  font-size: 1rem;
  color: light-dark(#212121, #aaa);
}

/* Highlighted keywords */
.highlight {
  background-color: var(--accent-color);
  color: #000000;
  padding: 0.1em 0.1em;
}

/* Remove "Show More" button */
.ai-overview-show-more {
  display: none;
}

/* Interest Card Styles */
.interest-card {
  background: light-dark(#f4f4f4, #2a2a2a);
  padding: 10px;
  margin: 10px 0;
  border-radius: 10px;
  border-left: 4px solid var(--accent-color);
  transition: transform 0.3s ease;
  cursor: pointer;
  height: auto;
  text-align: left;
  color: light-dark(#474545, #aaa);
}

.interest-card h3,
.interest-card p {
  text-align: left;
}

.interest-card p {
  text-align: left !important;
}

/* Tech Icons Styles */
.tech-icons {
  display: flex;
  gap: 20px;
  margin: 20px 0;
  flex-wrap: wrap;
}

.tech-icon {
  width: 50px;
  height: 50px;
  background: var(--accent-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 24px;
  transition: transform 0.3s ease;
}

.tech-icon:hover {
  transform: scale(1.1);
}

/* Contact Button Styles */
.contact-button {
  background-color: light-dark(var(--accent-color), var(--accent-color-dark));
  color: black;
  border: none;
  padding: 5px 10px;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.3s ease;
}

.contact-button:hover {
  background: #1c7a46;
  transform: scale(1.1);
}

.contact-button i {
  margin-right: 5px;
}

/* Running Animation Styles */
@keyframes running {
  0% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(10px);
  }
  100% {
    transform: translateX(0);
  }
}

.runner {
  display: inline-block;
  animation: running 2s infinite;
}

/* Contact Buttons Styles */
.contact-buttons {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.contact-button {
  background-color: light-dark(var(--accent-color), var(--accent-color-dark));
  color: white;
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-size: 1rem;
  font-weight: bold;
  transition: background 0.3s ease, transform 0.3s ease;
  display: inline-block;
  text-align: center;
}

.contact-button:hover {
  background: #1c7a46;
  transform: scale(1.1);
}

.contact-text {
  text-align: center;
  margin: 0 auto;
}

.fas,
.fab {
  margin-right: 5px;
}

.copy-icon {
  cursor: pointer;
  margin-left: 8px;
  opacity: 0.7;
  transition: all 0.3s ease;
}

.copy-icon:hover {
  opacity: 1;
  transform: scale(1.1);
  color: var(--accent-color);
}

@keyframes copyFeedback {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}

.copy-feedback {
  animation: copyFeedback 0.3s ease;
}

/* Certification Card Styles */
.certification-card {
  perspective: 1000px;
  margin: 0.5rem 0;
  min-height: 80px;
}

.card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 80px;
  transition: transform 0.6s;
  transform-style: preserve-3d;
}

.certification-card:hover .card-inner {
  transform: rotateY(180deg);
}

.card-front,
.card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  min-height: 80px;
  backface-visibility: hidden;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  box-sizing: border-box;
  background-color: light-dark(#f4f4f4, #333);
}

.card-front {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.card-front a {
  text-decoration: none;
}

.card-back {
  transform: rotateY(180deg);
  background-color: light-dark(#f4f4f4, #333);
  text-align: left;
}

.cert-view {
  text-decoration: underline;
  color: var(--accent-color);
  font-weight: bold;
  cursor: pointer;
}

/* Projects Section */
#projects {
  padding: 2rem 0; /* Increased padding */
  background-color: light-dark(#fff, #121212);
  margin-bottom: 4rem; /* Increased bottom margin */
}

/* Projects Carousel */
.projects-carousel {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
  position: relative;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.projects-carousel::-webkit-scrollbar {
  display: none;
}

/* Projects Grid */
.projects-grid {
  display: flex;
  gap: 2rem;
  animation: none;
}

#projects .project {
  flex: 0 0 calc(33.333% - 1.33rem);
  background-color: light-dark(#f4f4f4, #333);
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: light-dark(0 2px 8px rgba(0, 0, 0, 0.1), 0 2px 8px rgba(255, 255, 255, 0.1));
  margin-bottom: 1rem;
}

#projects .project img {
  width: 100%;
  height: auto;
  max-height: 140px;
  object-fit: contain;
  border-radius: 5px;
  margin-bottom: 1rem;
}

#projects .project h3 {
  font-size: 1rem;
  margin: 0.5rem 0;
  color: var(--accent-color);
}

#projects .project p {
  font-size: 0.75rem;
  line-height: 1.5;
  margin-bottom: 1rem;
  white-space: normal; /* Ensure text wraps to the next line */
  word-wrap: break-word; /* Break long words to fit within the container */
}

#projects .project a {
  display: inline-block;
  text-decoration: underline;
  color: var(--accent-color);
  font-weight: bold;
  transition: color 0.3s ease;
}

#projects .project a:hover {
  color: #32b76c;
}

/* Carousel Control */
.carousel-control {
  position: sticky;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border: none;
  background-color: light-dark(rgba(192, 192, 192, 0.5), rgba(255, 255, 255, 0.5));
  color: light-dark(#000, #fff);
  cursor: pointer;
  border-radius: 50%;
  z-index: 3;
}

.carousel-control.prev {
  left: 10px;
}

.carousel-control.next {
  left: calc(100% - 50px);
}

/* Interests Section */
#interests p {
  text-align: center;
  margin-top: 20px;
}

/* Search Results Box */
#search-results-box {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10000;
  overflow-y: auto;
  background-color: light-dark(#fff, #000);
  color: light-dark(#000, #fff);
  backdrop-filter: blur(5px);
  padding: 120px 10% 20px;
  max-width: 80%;
  margin: 0 auto;
}

#search-results-box .tab {
  position: relative;
}

#search-results-box .search-button:hover::after,
#search-results-box .tab:hover::after {
  content: "This is here for decoration😉";
  position: absolute;
  top: -40px;
  left: 50%;
  transform: translateX(-50%);
  background: light-dark(#333, #666);
  color: light-dark(#fff, #000);
  padding: 2px 5px;
  border-radius: 4px;
  font-size: 15px;
  white-space: nowrap;
}

#search-results-box .search-button:hover {
  transform: none !important;
}

/* Hamburger menu styles */
.hamburger-menu {
  display: none;
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 25px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 10;
}

.hamburger-menu span {
  width: 30px;
  height: 3px;
  background: var(--accent-color);
  border-radius: 10px;
  transition: all 0.3s linear;
}

/* Media queries for mobile view */
@media (max-width: 768px) {
  /* Prevent any horizontal overflow */
  html, body {
    max-width: 100%;
    overflow-x: hidden;
    position: relative;
  }

  /* Ensure all sections stay within viewport */
  main, #below-main, section {
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
  }

  /* Fix header width and position */
  header {
    width: 100%;
    left: 0;
    right: 0;
    box-sizing: border-box;
  }

  /* Fix main page section */
  #main-page {
    width: 100%;
    max-width: 100vw;
    overflow: hidden;
  }

  #main-page img {
    width: 100%;
    object-fit: cover;
  }

  /* Ensure certification panes don't overflow */
  .certification-panes {
    box-sizing: border-box;
  }

  /* Prevent any horizontal overflow */
  body {
    overflow-x: hidden;
  }
  
  /* Set header width to 100% and reset left offset */
  header {
    width: 100vw;
    left: 0;
  }

  /* Navigation bar */
  nav ul.right {
    flex-direction: column;
    gap: 0.5rem;
    width: 100%; /* Ensure it fits within the page width */
  }

  nav ul.right li {
    display: block;
    text-align: center;
    width: 100%; /* Ensure it fits within the page width */
  }

  /* Typing role */
  #main-page h2 {
    font-size: 2rem;
    padding-left: 10%;
  }

  #main-page p {
    font-size: 1rem;
    padding-left: 10%;
  }

  /* Skills panel */
  .skill-panes {
    flex-direction: column;
    gap: 1rem;
  }

  .certification-pane ul li {
    font-size: 0.9rem;
  }

  /* Projects view */
  #projects .project {
    flex: 1 1 auto;
    width: 200px; /* Full width for mobile view */
  }

  /* Contact section */
  .contact-buttons {
    flex-direction: column;
    gap: 0.5rem;
    width: 100%; /* Ensure it fits within the page width */
    align-items: center; /* Center the items */
  }

  .contact-button {
    width: 70%; /* Ensure it fits within the page width */
    text-align: center;
  }
  .search-input {
    font-size: 0.8rem;
  }
  /* Fix mobile scrolling issues */
  body {
    min-height: 100vh;
    overflow-y: auto;
  }

  main {
    margin-bottom: 0; /* Remove margin that might push content down */
    margin-top: 0;
    overflow-y: visible;
  }

  #below-main {
    overflow-y: visible;
    padding-bottom: 0; /* Remove extra padding */
    padding-left: 5%; /* Adjust left padding */
    padding-right: 5%; /* Adjust right padding */
  }

  /* Contact section fixes */
  #contact {
    padding-bottom: 2rem; /* Reduce padding */
    margin-bottom: 2rem;
    position: relative;
    overflow: visible;
  }

  /* Footer fixes for mobile */
  footer {
    margin-top: 1rem;
    padding: 1rem 0;
    position: relative;
    bottom: auto;
    height: auto; /* Allow footer to expand based on content */
  }

  footer table {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.5rem;
    height: auto; /* Allow table to expand */
  }

  footer table td {
    text-align: center;
    padding: 0.3rem 0;
    white-space: nowrap; /* Prevent text wrapping */
  }

  /* Footer mobile styles */
  footer {
    margin-top: 1rem;
    padding: 1rem 0;
    position: relative;
    height: auto;
  }

  footer table,
  footer tr {
    display: flex;
    flex-direction: column;
    width: 100%;
  }

  footer td {
    width: 100%;
    display: block;
    text-align: left;
    padding: 0.5rem 0;
    margin: 0.2rem 0;
    gap: 1rem;
  }

  footer td br {
    display: none; /* Remove line breaks in copyright text */
  }

  footer td:last-child {
    margin-top: 1rem;
    border-top: 1px solid var(--accent-color);
    padding-top: 1rem;
  }

  /* Certifications panel for mobile */
  .certification-panes {
    position: relative;
    overflow-x: hidden;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }

  .certification-pane {
    flex: 0 0 100%;
    scroll-snap-align: start;
    margin-right: 1rem;
    transition: transform 0.3s ease;
    display: flex;
    justify-content: center; /* Center the certification-cards */
  }

  .certification-card {
    width: 90%; /* Adjust width to fit within the mobile view */
    margin: 0 auto; /* Center the card */
  }

  /* Fix contact section visibility */
  #contact {
    padding-bottom: 100px; /* Add extra padding at bottom */
  }

  footer {
    position: relative; /* Change from fixed to relative */
    padding-bottom: 100%;
  }

  footer table {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem;
  }

  footer table td {
    text-align: center;
    padding: 5px 0;
  }

  /* Header width adjustment for mobile */
  header {
    width: 100vw; /* Match the width of the area underneath */
  }

  /* Navigation changes */
  .hamburger-menu {
    display: flex;
    margin-right: 20px;
  }

  nav ul.right {
    display: flex; /* Change to flex instead of none */
    position: fixed;
    top: 60px;
    left: 0;
    width: 100%;
    background: light-dark(rgba(255, 255, 255, 0.95), rgba(18, 18, 18, 0.95));
    flex-direction: column;
    padding: 20px 0;
    backdrop-filter: blur(10px);
    z-index: 1000;
    
    /* Add animation properties */
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
  }

  nav ul.right.show {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  nav ul.right li {
    margin: 10px 0;
  }

  /* Certifications panel for mobile */
  .certification-panes {
    position: relative;
    overflow-x: hidden;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }

  .certification-pane {
    scroll-snap-align: start;
    margin-right: 1rem;
    transition: transform 0.3s ease;
    display: flex;
    justify-content: center; /* Center the certification-cards */
  }

  .certification-card {
    width: 70%; /* Adjust width to fit within the mobile view */
    margin: 0 auto; /* Center the card */
  }

  /* Add navigation dots for certification panes */
  .certification-nav-dots {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
    gap: 0.5rem;
  }

  .certification-nav-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: light-dark(#ccc, #444);
    cursor: pointer;
  }

  .certification-nav-dot.active {
    background: var(--accent-color);
  }

  /* Fix contact section visibility */
  #contact {
    padding-bottom: 100px; /* Add extra padding at bottom */
  }

  footer {
    position: relative; /* Change from fixed to relative */
    padding-bottom: 100%;
  }

  footer table {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem;
  }

  footer table td {
    text-align: center;
    padding: 5px 0;
  }

  /* Global container styles */
  #below-main, section, .projects-carousel, .certification-panes {
    width: 90%; /* Set consistent width */
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
  }

  /* Reset any existing padding */
  #below-main {
    padding: 0;
    width: 90%;
    margin: 0 auto;
  }

  /* Ensure sections don't overflow */
  section {
    max-width: 90%;
    overflow-x: hidden;
  }

  /* Adjust quote sections to fit */
  .quote {
    width: 100%;
    box-sizing: border-box;
    margin-left: 0;
    margin-right: 0;
  }

  /* Ensure projects stay within bounds */
  #projects {
    padding: 2rem 0;
    width: 90%;
    margin: 0 auto;
    overflow: hidden; /* Remove scroll */
  }

  .projects-carousel {
    overflow-x: auto;
    overflow-y: hidden; /* Remove vertical scroll */
    width: 100%;
  }

  .projects-grid {
    width: max-content; /* Allow content to determine width */
    padding-bottom: 1rem; /* Add some padding to prevent cut-off */
  }

  /* Center certification panes and cards */
  .certification-panes {
    display: flex;
    flex-direction: column;
  }

  .certification-pane {
    margin: 1rem 0;
    box-sizing: border-box;
  }

  .certification-card {
    width: 100%;
    margin: 0.5rem 0;
  }

  .card-front, 
  .card-back {
    width: 100%;
    text-align: center;
    box-sizing: border-box;
  }

  /* Fix contact section visibility */
  #contact {
    padding-bottom: 100px; /* Add extra padding at bottom */
  }

  footer {
    position: relative; /* Change from fixed to relative */
    padding-bottom: 30vh;
  }

  footer table {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem;
  }

  footer table td:not(:last-child) {
    text-align: left;
    padding: 5px 0;
    padding-left: 33%;
  }
  
  /* Simplified certification styles for mobile */
  .certification-panes {
    width: 95%; /* Increase width to use more screen space */
    margin: 0 auto;
    padding: 0;
    display: flex;
    flex-direction: column;
  }

  .certification-pane {
    margin: 0.5rem 0; /* Reduced vertical margins */
    padding: 0.5rem; /* Reduced padding */
  }

  .certification-card {
    width: 80%;
    margin: 0.5rem 0;
  }

  .card-front, 
  .card-back {
    padding: 0.5rem;
  }

  /* Fix about section scrolling */
  #about {
    overflow-y: hidden;
    max-height: none;
  }

  /* Smaller text for About Me section */
  #about .about-text {
    font-size: 1rem;
  }

  /* Smaller text for Quote sections */
  .quote .quote-text {
    font-size: 1.2rem;
  }

  .quote .quote-author {
    font-size: 1rem;
  }

  /* Smaller text for Skills section */
  #skills h2 {
    font-size: 1.5rem;
  }

  .skill-pane ul li {
    font-size: 0.9rem;
  }
}
