:root {
  --body-bg: #ffffff;
  --card-bg: whitesmoke;
  --text-color: #333333;
  --link-color: #0000ff;
}

.dark-mode {
  --body-bg: #070707;
  --card-bg: #171717;
  --text-color: #f4f3f3;
  --link-color: #44a7ff;
}

* {
  padding: 0;
  margin: 0;
  font-family: "Source Code Pro", monospace;
  font-weight: 300;
}
body {
  color: var(--text-color);
  background: var(--body-bg);
  transition: background-color 0.5s ease;
}
header .content-header {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  min-height: 65vh;
  background-attachment: fixed;
  position: relative;
}
header .header-title {
  font-weight: 300;
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}
header .content-header p {
  margin-bottom: 1.5rem;
  text-align: center;
  max-width: 70vw;
}
header .header-title strong {
  font-weight: 700;
}

header .content-header .icon {
  width: 16px;
  height: 16px;
  display: inline-block;
  margin: 2px 5px;
  /* cursor: pointer; */
  color: #111;
  color: var(--text-color);
  opacity: 0.7;
  transition: 0.3s all;
}
header .content-header .icon:hover {
  opacity: 1;
  color: #188b66;
}

header .content-header .icon svg {
  width: 100%;
  height: 100%;
}

/* //// */

.section-content {
  padding: 1rem;
  min-height: 55vh;
  margin-bottom: 10rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.section-content h2 {
  text-align: center;
  font-weight: 700;
  margin-bottom: 3.5rem;
  font-size: 2rem;
  position: relative;
}
.section-content h2::after {
  content: "";
  display: block;
  width: calc(100% - 40px);
  height: 2px;
  background-color: var(--text-color);
  margin: 0 auto;
  border-radius: 10px;
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
}
.section-content h2::before {
  content: "";
  display: block;
  width: 20px;
  height: 2px;
  background-color: var(--body-bg);
  margin: 0 auto;
  border-radius: 10px;
  bottom: -5px;
  position: absolute;
  z-index: 2;
  right: 40px;
}
.section-content .about-content-small {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}

.about-me-section .about-content {
  display: flex;
  gap: 4rem;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-end;
}
.section-content .profile-img {
  position: relative;
}
.section-content .profile-img::after {
  content: "";
  width: calc(100% - 2rem);
  height: 30%;
  display: block;
  background: linear-gradient(180deg, #07070700, var(--body-bg));
  position: absolute;
  bottom: -1px;
  left: 0;
}

.section-content .profile-img img {
  width: 100%;
  height: 100%;
  max-width: 300px;
  object-position: top;
  object-fit: contain;
  margin-right: 2rem;
}
.section-content .about-content-info {
  padding: 1rem;
  width: 30vw;
}
.section-content .about-content-info h4 {
  font-size: 2rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
}
.section-content .about-content-info .job-title {
  font-size: 1.5rem;
  font-weight: 400;
  margin-bottom: 1.5rem;
  color: #188b66;
}
.section-content .about-content-info-p {
  max-width: 60vw;
}

.card {
  position: relative;
  overflow: hidden;
  border: 1px solid;
  /* min-width: 420px;
  max-width: 500px; */
}
.card .card-img {
  width: 100%;
  position: relative;
}
.card .card-img::before {
  width: 100%;
  height: 100%;
  content: "";
  position: absolute;
  background: rgba(0, 0, 0, 0.189);
  z-index: 2;
  top: 0;
  opacity: 0;
  transition: 0.3s all;
}
.card:hover .card-img::before {
  opacity: 1;
}
.card .card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: 0.3s all;
}
.card-container .card .card-img {
  overflow: hidden !important;
}
.card-container .card:hover .card-img img {
  transform: scale(1.1);
}
.card .card-info {
  position: absolute;
  z-index: 2;
  bottom: 0;
  width: -webkit-fill-available;
  padding: 0.5rem 2rem;
  transition: 0.3s all;
  background: var(--body-bg);
  display: flex;
  justify-content: space-between;
}
.card:hover .card-info {
  padding: 2rem;
}
.card .card-info h4 {
  font-weight: 400;
}
.card .card-info a {
  opacity: 0;
  display: flex;
  align-items: center;
  text-decoration: none;
  color: var(--link-color);
  position: relative;
  /* cursor: pointer; */
  transition: 0.3s all;
}
.card:hover .card-info a {
  opacity: 1;
}
.card .card-info svg {
  margin-bottom: -2px;
  margin-right: 3px;
}
.card .card-info a::before {
  content: "";
  width: 100%;
  position: absolute;
  height: 1px;
  background: var(--link-color);
  z-index: 1;
  display: block;
  bottom: 0;
}
.title-info {
  text-align: left;
  width: 100%;
  padding: 0 4rem;
  margin-bottom: 2rem;
}
.card-list {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 1rem;
  max-width: 50%;
  background: var(--card-bg);
  position: relative;
}
.card-list .card-img {
  margin-right: 5px;
}
.card-list::after {
  content: "";
  width: var(--random-width, 80%); /* Fallback to 80% */
  height: 80%;
  position: absolute;
  top: 13px;
  right: -5px;
  z-index: -1;
  border-right: 3px solid var(--random-color, #188b66);
  border-bottom: 3px solid var(--random-color, #188b66);
}
footer {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  font-size: 14px;
}
footer svg {
  width: 30px;
  transition: 0.3s all;
}
footer:hover svg {
  fill: red;
  transform: scale(1.1);
}

.card-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  grid-auto-rows: 300px;
  gap: 1.4rem;
  padding: 2rem;
  width: 100%;
  max-width: 1200px;
}
.card-container .card {
  overflow: initial !important;
}
.card-container .card::after {
  content: "";
  width: var(--random-width, 70%); /* Fallback to 80% */
  height: 65%;
  position: absolute;
  z-index: -1;
  bottom: -10px;
  right: -10px;
  border-right: 4px solid var(--random-color, #188b66);
  border-bottom: 4px solid var(--random-color, #188b66);
}
.loading-img {
  position: absolute;
  top: 0;
  right: 50%;
  animation: pulse 1.5s infinite;
  height: 200px;
  width: 140px;
  transform: translate(0%, -100%);
}
.d-none {
  display: none !important;
}
@keyframes pulse {
  0% {
    opacity: 0.6;
  }
  50% {
    opacity: 1;
  }
  100% {
    opacity: 0.6;
  }
}
/* Make every second card span two rows for the mosaic effect */
.card:nth-child(odd) {
  grid-row: span 2;
}

.toggle-dark-mode {
  position: fixed;
  top: 5px;
  right: 8px;
  z-index: 1000;
  background: var(--body-bg);
  padding: 5px;
  border: 1px solid var(--text-color);
}
.toggle-dark-mode svg {
  transform-origin: center;
  width: 25px;
  height: 25px;
}
.bg-menu {
  width: 35px;
  height: 35px;
  background: transparent;
  position: absolute;
  top: 3px;
  right: -6px;
  z-index: -1;
  border-right: 3px solid #188b66;
  border-bottom: 3px solid #188b66;
}
.sun-rays {
  opacity: 0;
  transition: all 0.7s ease-out;
}
.sun-rays.show-rays {
  opacity: 1;
}
*,
body {
  cursor: none !important;
}

#cursor,
#cursor-follow {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%); /* Center both circles on the cursor */
}

#cursor {
  width: 8px;
  height: 8px;
  background-color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: width 0.3s ease-out, height 0.3s ease-out,
    background-color 0.3s ease-out;
}

#cursor-follow {
  width: 30px;
  height: 30px;
  background-color: rgba(0, 0, 0, 0.1);
  transition: width 0.3s ease-out, height 0.3s ease-out,
    background-color 0.3s ease-out;
  top: -11px;
  left: -11px;
  transform: translate(-50%, -50%);
}

.hover-effect #cursor {
  width: 25px;
  height: 25px;
  background-color: #000000;
  opacity: 0.7;
}

.hover-effect #cursor-follow {
  width: 45px;
  height: 45px;
  background-color: transparent;
  border: 1px solid #1a1a1a;
}
.dark-mode #cursor {
  background-color: #fff;
}
.dark-mode #cursor-follow {
  background-color: rgba(255, 255, 255, 0.5);
}
.dark-mode.hover-effect #cursor-follow {
  border: 1px solid #eaeaea;
}

/* //icons */
/* @keyframes flicker {
  0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% {
    opacity: 1;
  }
  20%, 24%, 55% {
    opacity: 0.5;
  }
} */
.bulb-container {
  position: relative;
  display: inline-block;
}

.bulb-container::after {
  content: "";
  position: absolute;
  top: calc(50% - 2px);
  left: 50%;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, rgb(240 223 53 / 80%), transparent);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  animation: flickerGlow 2s infinite;
}

@keyframes flickerGlow {
  0%,
  19%,
  21%,
  23%,
  25%,
  28%,
  30%,
  32%,
  35%,
  100% {
    opacity: 0.5;
  }
  20%,
  24%,
  29%,
  31%,
  36% {
    opacity: 1;
  }
  37%,
  99% {
    opacity: 0;
  }
}

.icon-bolt path {
  stroke: rgba(255, 255, 0, 0.8);
  stroke-width: 0.5;
  animation: electric-spark 1.2s infinite;
  animation-timing-function: cubic-bezier(0.25, 1, 0.5, 1); /* Custom easing */
}

@keyframes electric-spark {
  0% {
    stroke-width: 0.6;
    stroke: rgba(255, 255, 0, 0.6);
  }
  25% {
    stroke-width: 0.8;
    stroke: rgba(255, 255, 255, 1);
  }
  50% {
    stroke-width: 0.4;
    stroke: rgb(254, 191, 102);
  }
  75% {
    stroke-width: 1.2;
    stroke: rgba(255, 255, 255, 0.8);
  }
  100% {
    stroke-width: 0.6;
    stroke: rgba(255, 255, 0, 0.6);
  }
}

.icon-ruler path {
  stroke-dasharray: 500;
  stroke-dashoffset: 500;
  animation: drawRuler 3s infinite ease-in-out;
  fill: none;
  stroke: currentColor;
  stroke-width: 1;
}

@keyframes drawRuler {
  0%,
  100% {
    stroke-dashoffset: 500;
  }
  50% {
    stroke-dashoffset: 0;
  }
}

.icon-code-slash path {
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: drawCode 2s infinite ease-in-out;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

@keyframes drawCode {
  0% {
    stroke-dashoffset: 100;
  }
  50% {
    stroke-dashoffset: 0;
  }
  100% {
    stroke-dashoffset: 100;
  }
}

@keyframes rotateNeedle {
  0% {
    transform: rotate(0deg);
  }
  50% {
    transform: rotate(25deg);
  }
  100% {
    transform: rotate(0deg);
  }
}

.icon-gauge path:first-of-type {
  transform-origin: 50% 50%;
  animation: rotateNeedle 2s infinite ease-in-out;
}

@keyframes arrowsContract {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
  50% {
    transform: translate(-5px, 5px) rotate(5deg); /* Adjust values as needed */
  }
}

.icon-arrows {
  animation: arrowsContract 2s infinite ease-in-out;
  transform-origin: center;
}
.hideimg {
 visibility: hidden;
 position: absolute;
}

@media only screen and (max-width: 600px) {
  header .content-header {
    align-items: start;
  }
  header .content-header h2 {
    padding: 0 2rem;
  }
  header .content-header p {
    text-align: left;
    max-width: 100%;
    padding: 0 2rem;
  }
  header .social-header {
    margin-left: 2rem;
  }
  /* .section-content {
    width: 100%; */
  /* } */
  #cursor,
  #cursor-follow {
    opacity: 0 !important;
  }
  .section-content .profile-img::after {
    width: 100%;
  }
  .section-content .profile-img img {
    max-width: 100%;
    margin: 0;
  }
  .section-content .about-content-info {
    width: 100%;
    padding: 0;
  }
  .section-content .about-content-info-p {
    max-width: 100%;
  }
  .section-content .about-content {
    gap: 1rem;
  }
  .card-list {
    max-width: 100%;
  }
  .card {
    min-width: 300px;
  }
  .card .card-info a {
    opacity: 1;
  }
  .loading-img {
    transform: translate(50%, -10%);
  }
}
