@import url("https://fonts.googleapis.com/css2?family=Anek+Latin:wght@400;500;600&family=Battambang:wght@400;700&display=swap");
:root {
  --primary: #18181b;
  --secondary: #27272a;
  --third: #ff3333;
  --dark: #18181b;
  --light: #f4f4f5;
  --white: #fff;
  --hv-color: #f1f1f1;
  --foreground: var(--secondary);
  --background: var(--light);
  --card: var(--white);
  --hover: var(--hv-color);
  --contrast-fg: var(--light);
  --contrast-bg: var(--primary);
  --box-shadow: rgba(60, 64, 67, 0.3) 0px 1px 2px 0px,
    rgba(60, 64, 67, 0.15) 0px 2px 6px 2px;
  --box-sd-1: rgba(0, 0, 0, 0.1) 0px 4px 6px -1px,
    rgba(0, 0, 0, 0.06) 0px 2px 4px -1px;
  --box-sd-2: rgba(60, 64, 67, 0.3) 0px 1px 2px 0px,
    rgba(60, 64, 67, 0.15) 0px 2px 6px 2px;
}

.darkmode {
  --primary: #18181b;
  --secondary: #27272a;
  --third: #ff3333;
  --dark: #18181b;
  --light: #f4f4f5;
  --white: #fff;
  --soft-dark: #efefef29;
  --dim-light: #e5e5e5e2;
  --foreground: var(--dim-light);
  --background: var(--dark);
  --card: var(--secondary);
  --hover: var(--soft-dark);
  --contrast-fg: var(--primary);
  --contrast-bg: var(--light);
}

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

body {
  font-family: "Anek Latin", sans-serif, "Battambang", cursive;
  color: var(--foreground);
  background-color: var(--background);
}

h1,
h2,
h3,
h4,
h5 {
  margin: 0;
}

a {
  text-decoration: none;
}

.header {
  background: var(--card);
  height: 60px;
}
.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}
.header .logo a img {
  height: 45px;
  transition: transform 0.2s ease-out;
}
.header .logo a img:hover {
  transform: scale(1.2);
  transform: rotate(-10deg);
}
.header .logo > a {
  display: flex;
}
.header .nav-menu ul {
  display: flex;
  gap: 20px;
  align-items: center;
}
.header li {
  list-style: none;
}
.header ul li a {
  font-size: 18px;
  color: var(--foreground);
  padding: 6px 15px;
  text-transform: uppercase;
  border-radius: 5px;
  transition: all 0.2s ease-out;
}
.header ul li a:hover {
  background: var(--hover);
  padding: 6px 15px;
}
.header .btn::before {
  border-radius: 5px;
}
.header .dark-mode-toggle {
  background: none;
  border: none;
  font-size: 18px;
  border-radius: 5px;
  color: var(--foreground);
  display: flex;
  margin-left: 10px;
}
.header .dark-mode-toggle i {
  margin-right: 0;
  cursor: pointer;
}

.showcase {
  margin-top: 20px;
}
.showcase h2 {
  font-size: 2rem;
  font-weight: 400;
}
.showcase h1 {
  font-size: 3rem;
  font-weight: 600;
}
.showcase .gallery-grid {
  grid-template-columns: repeat(2, 350px);
  justify-content: center;
  gap: 20px;
  padding-top: 100px;
  padding-bottom: 100px;
}
.showcase .gallery-grid .card {
  color: var(--foreground);
  box-shadow: var(--box-sd-1);
  padding: 20px;
  text-align: center;
  height: 200px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
}
.showcase .gallery-grid .button {
  display: flex;
  gap: 5px;
  align-items: center;
  justify-content: center;
}
.showcase .social-link h3 {
  font-size: 1.3rem;
  margin-bottom: 5px;
}
.showcase .social-link i {
  font-size: 35px;
  color: var(--foreground);
  transition: all 0.2s ease-in;
}
.showcase .social-link i:hover {
  color: var(--third);
  transform: scale(1.2);
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

p {
  line-height: 1.3;
}

i {
  margin-right: 5px;
}

.heading {
  font-size: 2rem;
  font-weight: 500;
  text-align: center;
  width: 15%;
  border-bottom: var(--third) 2px solid;
  padding-bottom: 3px;
  margin: 30px auto 40px auto;
  color: var(--foreground);
}

.sub-heading {
  font-size: 1.5rem;
  font-weight: 500;
  text-transform: uppercase;
  margin: 0 0 15px;
}
.sub-heading span {
  color: var(--alt-color);
}

.sub-heading-bg {
  background: var(--secondary);
  box-shadow: var(--box-sd-1);
  color: var(--white);
  padding: 8px 10px;
  border-radius: 5px;
  display: inline-block;
}
.sub-heading-bg i {
  color: var(--third);
  height: 100%;
  border-radius: 5px;
  font-size: 20px;
}

.third-heading {
  font-size: 1.2rem;
  font-weight: 600;
  text-transform: capitalize;
  margin-bottom: 20px;
}
.third-heading span {
  padding-bottom: 5px;
  border-bottom: 2px solid var(--third-color);
}

.title {
  font-size: 1.2rem;
  font-weight: 600;
}

.sub-title,
.sub-date {
  opacity: 0.75;
}

.sub-title {
  margin-bottom: 2px;
}

.icon {
  background: var(--secondary);
  color: var(--third);
  padding: 10px;
  border-radius: 5px;
}

.btn {
  padding: 10px 15px;
  border: none;
  background: var(--contrast-bg);
  color: var(--contrast-fg);
  text-transform: uppercase;
  border-radius: 3px;
  display: inline-block;
  position: relative;
  z-index: 1;
}

.btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  z-index: -1;
  background-color: var(--third);
  border-radius: 3px;
  transition: transform 0.2s ease-in;
  transform: scaleX(0);
  transform-origin: left;
}

.btn:hover::before,
.btn:focus::before {
  transform: scaleX(1);
}

.btn-primary {
  color: var(--background);
  transition: all 0.2s ease-out;
  white-space: nowrap;
}
.btn-primary:hover {
  border-bottom: 3px solid var(--foreground);
}

.btn-secondary {
  background-color: var(--third);
  color: var(--white);
}

.btn-secondary::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  z-index: -1;
  background-color: var(--primary);
  border-radius: 3px;
  transition: transform 0.2s ease-in;
  transform: scaleX(0);
  transform-origin: left;
}

.btn-third {
  background: var(--third-color);
}

.card {
  box-shadow: var(--box-sd-1);
  border-bottom: 4px solid var(--foreground);
  transition: all 0.4s ease-out;
  background-color: var(--card);
  color: var(--foreground);
}
.card .card-body {
  display: block;
}
.card .card-header {
  padding: 10px;
  text-align: center;
  color: var(--primary);
}
.card .card-header .img-icon {
  box-shadow: var(--box-sd-1);
  background-color: var(--background);
  padding: 3px;
  width: 40px;
  height: 40px;
  border-radius: 5px;
  transition: transform 0.4s ease-out;
}
.card .card-header p {
  font-size: 17px;
  font-weight: 600;
}
.card .card-logo {
  width: 60px;
  height: 60px;
  box-shadow: var(--box-sd-1);
  border-radius: 50%;
}
.card .card-title {
  color: var(--foreground);
}
.card:hover {
  transform: scale(1.03);
  border-bottom: 4px solid var(--third);
}
.card:hover .img-icon {
  transform: scale(1.1);
}

.mt-1 {
  margin-top: 5px;
}

.mt-2 {
  margin-top: 10px;
}

.my-2 {
  margin: 10px 0;
}

.mb-1 {
  margin-bottom: 5px;
}

.mb-2 {
  margin-bottom: 10px;
}

.p-1 {
  padding: 5px;
}

.active {
  padding: 6px 15px;
  border-radius: 5px;
  background-color: var(--third);
  color: var(--white) !important;
}
.active:hover {
  background-color: var(--third) !important;
  color: var(--white) !important;
}

.hidden {
  display: none;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(3px);
          backdrop-filter: blur(3px);
  z-index: 5;
}

.dark {
  background-color: #333;
}

.flex-super,
.flex-box {
  display: flex;
  gap: 20px;
}

.flex-super-item,
.flex-item {
  flex: 1;
}

.sub-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 25px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
  margin-bottom: 25px;
}

.modals .container-flex {
  display: flex;
  align-items: flex-start;
  justify-content: space-evenly;
  gap: 30px;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: auto;
  background-color: var(--card);
  padding: 2rem;
  border-radius: 5px;
  z-index: 10;
}
.modals .container-flex .img img {
  width: 250px;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
}
.modals .container-flex .desc h2 {
  font-size: 18px;
  margin: 0;
  line-height: 1.5;
  color: var(--foreground);
  text-transform: none;
}
.modals .container-flex .desc h2 span {
  font-weight: normal;
}
.modals .container-flex .desc h2 a {
  color: var(--third);
  font-weight: normal;
}
.modals .container-flex .desc p {
  margin-bottom: 25px;
}
.modals .container-flex .close-modal {
  position: absolute;
  top: 0.4rem;
  right: 0.6rem;
  font-size: 2rem;
  color: var(--foreground);
  cursor: pointer;
  border: none;
  background: none;
  transition: transform 0.15s ease-out;
}
.modals .container-flex .close-modal:hover {
  transform: scale(1.2);
}

.skeleton {
  animation: skeleton 1s ease-out infinite alternate;
  background-color: #d3d3d3;
}

@keyframes skeleton {
  to {
    opacity: 0.5;
  }
}
@media (max-width: 400px) {
  .modals .container-flex {
    display: block;
    width: 80%;
  }
  .modals .container-flex .img {
    margin-bottom: 20px;
  }
}
@media (max-width: 900px) {
  .modals .container-flex {
    width: 80%;
  }
  .modals .container-flex .img img {
    width: 150px;
  }
}
.portfolio .card .card-body {
  width: 100%;
}
.portfolio .web-container,
.portfolio .side-container {
  cursor: pointer;
}
.portfolio .web-container .card .card-body,
.portfolio .side-container .card .card-body {
  width: 100%;
  height: 200px;
  -o-object-fit: contain;
     object-fit: contain;
}
.portfolio .media .gallery-grid {
  grid-template-columns: repeat(4, 1fr);
}

.about .card {
  padding: 20px;
}
.about .gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 40px;
}
.about .gallery-grid a {
  color: inherit;
}

@media (max-width: 1023px) {
  .heading {
    width: 15%;
    font-size: 1.6rem;
  }
  .sub-heading {
    font-size: 1.3rem;
  }
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .about .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .portfolio .web .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .portfolio .media .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .modal .container-flex {
    gap: 15px;
    width: 90%;
  }
  .modal .container-flex .close-modal {
    top: 0.4rem;
    right: 0.6rem;
    font-size: 1.5rem;
    transition: transform 0.15s ease-out;
  }
  .modal .container-flex .close-modal:hover {
    transform: scale(1.1);
  }
}
@media (max-width: 767px) {
  .header {
    height: 100%;
    padding: 10px 0;
  }
  .header .container {
    flex-direction: column;
    gap: 10px;
  }
  .header .nav-menu ul {
    display: flex;
    gap: 2px;
  }
  .header li {
    margin-bottom: 6px;
  }
  .about .gallery-grid {
    grid-template-columns: repeat(1, 1fr);
  }
  .showcase .gallery-grid {
    grid-template-columns: repeat(1, 1fr);
    padding-top: 0;
  }
  .showcase .gallery-grid .card {
    border-bottom: 4px solid rgba(51, 51, 51, 0.514);
    height: 150px;
  }
  .portfolio .web .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .portfolio .media .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .heading {
    width: 35%;
    font-size: 1.5rem;
    margin: 30px auto;
  }
  .sub-heading {
    font-size: 1.25rem;
  }
  .modal .container-flex {
    flex-direction: column;
    gap: 15px;
    width: 90%;
  }
  .modal .container-flex .item-flex {
    width: auto;
    flex-grow: 0;
  }
}