/*
Theme Name: My Classic Theme
Theme URI: https://yourwebsite.com/
Author: Chienhv
Description: A simple classic WordPress theme.
Version: 1.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: my-classic-theme
*/

body,
html {
  margin: 0;
  padding: 0;
  font-family: Arial, sans-serif;
  overflow-x: hidden;
  overscroll-behavior: none;
}

/* Admin margin top */
html {
  margin-top: 0px !important;
}

/* HeaderBar */
.logo {
  font-size: 24px;
  font-weight: bold;
}

.logo img {
  max-width: 150px;
  height: auto;
}

#logo {
  margin-top: 5px;
}

.header {
  padding: 16px 40px;
  display: flex;
  justify-content: space-between;
  width: 100vw;
  align-items: center;
  position: absolute;
  z-index: 10;
  box-sizing: border-box;

}

.logo a {
  text-decoration: none;
  height: 28px;
}

.text-logo {
  font-family: 'Maison Neue', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: white;
  text-decoration: none;
  letter-spacing: 6px;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.menu-icon {
  font-size: 42px;
  cursor: pointer;
  color: white;
  user-select: none;
  font-weight: 400;
  letter-spacing: 25%;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.menu-icon.dark {
  color: black;
  text-shadow: none;

}

/* HeaderBar */

/* Menu Overlay */
.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: white;
  display: none;
  align-items: center;
  justify-content: center;
  text-align: center;
  z-index: 100;
}

.menu-overlay.active {
  display: flex;
}

.menu-content {
  display: flex;
  gap: 40px;
  width: 100%;
  height: 100%;
}

/* Cột Categories và Post List */
.menu-columns {
  display: flex;
  gap: 40px;
  width: 100%;
  user-select: none;
  justify-content: space-between;
}

.menu-column {
  min-width: 200px;
  text-align: left;
  padding-left: 40px;
  padding-top: 18px;
}

.menu-categories {
  display: flex;
  flex-direction: column;
}

.menu-column h2 {
  border-bottom: 2px solid #000;
  padding-bottom: 10px;
}

.menu-column ul {
  list-style: none;
  padding: 0;
}

.menu-column ul li {
  margin: 10px 0;
}

.menu-column ul li a {
  color: #000;
  text-decoration: none;
  font-size: 18px;
}

.close-menu {
  position: fixed;
  top: 24px;
  right: 40px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1000;
}

.close-menu div {
  position: absolute;
  width: 28px;
  height: 3px;
  background-color: black;
}

.bar1 {
  animation: rotateBar1 0.69s ease forwards;
}

.bar2 {
  animation: rotateBar2 0.69s ease forwards;
}

@keyframes rotateBar1 {
  0% {
    transform: translateY(0px) rotate(0);
  }

  50% {
    transform: translateY(0) rotate(0);
  }

  100% {
    transform: translateY(0) rotate(45deg);
  }
}

@keyframes rotateBar2 {
  0% {
    transform: translateY(4px) rotate(0);
  }

  50% {
    transform: translateY(0) rotate(90deg);
  }

  100% {
    transform: translateY(0) rotate(135deg);
  }
}

/* Menu Overlay */


/* Homepage css*/
.hero-image-stack {
  position: relative;
  width: 100%;
  height: 100%;
}

.hero-image-stack img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  top: 0;
  left: 0;
  transition: transform 1s ease-in-out;
  opacity: 1;
}

img.image-top {
  z-index: 3;
}

img.image-middle {
  z-index: 2;
}

img.image-bottom {
  z-index: 1;
}

img.slide-out-left {
  animation: shrinkOutLeft 0.6s ease-in-out forwards;
}

img.slide-out-right {
  animation: shrinkOutRight 0.6s ease-in-out forwards;
}

@keyframes shrinkOutLeft {
  0% {
    clip-path: inset(0% 0% 0% 0%);
  }

  100% {
    clip-path: inset(0% 100% 0% 0%);
  }
}

@keyframes shrinkOutRight {
  0% {
    clip-path: inset(0% 0% 0% 0%);
  }

  100% {
    clip-path: inset(0% 0% 0% 100%);
  }
}

.hero-section {
  width: 100%;
  height: 100vh;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

/* Sliding Animation */
.hero-clone {
  position: absolute;
  width: 100%;
  top: 0;
  left: 0;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  user-select: none;
  -webkit-user-drag: none;
  /* z-index: 1; */
}

.hero-title {
  position: absolute;
  left: 40px;
  bottom: 10px;
  font-size: 50px;
  font-weight: 400;
  letter-spacing: 25%;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  color: white;
  z-index: 9;
  line-height: 120%;
  font-family: 'Anton', sans-serif;
  text-transform: uppercase;
}

/* Homepage css*/


/* Menu Categories css */
.menu-category-item {
  width: fit-content;
  height: 36px;
  opacity: 0.5;
  transition: opacity 0.3s ease;
}

.menu-category-item.active {
  opacity: 1;
}

.first-letter {
  font-family: 'Anton', sans-serif;
  display: inline-block;
  width: fit-content;
  height: 40px;
  line-height: 40px;
  text-align: center;
  font-weight: 400;
  font-size: 24px;
  text-transform: uppercase;
  color: #3B3839;
  vertical-align: baseline;
}

.rest-text {
  font-family: 'Manrope', sans-serif;
  font-weight: 400;
  font-size: 24px;
  line-height: 40px;
  letter-spacing: 0%;
  text-align: justify;
  vertical-align: baseline;
  color: #3B3839;
}

/* Menu footer */
.menu-footer {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: left;
  padding: 20px 40px;
  color: white;
  position: absolute;
  bottom: 0;
  left: 5px;
}

.menu-footer a {
  text-decoration: none;
  color: #858383;
  font-family: 'Manrope', sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 125%;
  letter-spacing: 0.5%;
}

.menu-footer a:hover {
  text-decoration: underline;
}

/* Menu post css */
.right-menu {
  width: 100%;
  display: flex;
  justify-content: flex-end;
  padding-right: 40px;
}

.custom-space {
  padding-top: 40px;
}

.no-posts {
  text-align: center;
  font-size: 20px;
  color: #888;
  padding: 18px 0;
  font-family: 'Manrope', sans-serif;
}

.posts-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 44px;
  max-height: 100vh;
  overflow-y: scroll;
  padding: 10px;
  width: 100%;
  scrollbar-width: none;
  scroll-behavior: smooth;
  padding-top: 80px;
  padding-bottom: 40px;
}

.post-item {
  aspect-ratio: 1/1;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  cursor: pointer;
  opacity: 0;
  transform: translateY(30px);
  background: #fff;
  animation: fadeInUp 0.3s ease-in-out forwards;
  transition: all 0.3s ease-in-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}


.post-item .post-image-wrapper {
  width: 100%;
  height: 75%;
  object-fit: cover;
  border-top-right-radius: 4px;
  border-top-left-radius: 4px;
  overflow: hidden;
}

.post-item .post-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-item.vertical .post-title-inside {
  left: 0;
  bottom: 0;
}

.post-item.horizontal .post-title-inside {
  left: 0;
  top: 0;
}

.post-title-inside {
  position: absolute;
  width: 68%;
  padding: 6px 10px;
  color: white;
  font-size: 18px;
  font-family: 'Manrope', sans-serif;
  text-align: left;
  z-index: 2;
  line-height: 1.4;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  text-transform: uppercase;
  font-weight: bold;
}

.post-item.vertical {
  flex-direction: row;
}

.post-item.vertical .post-image-wrapper {
  width: 70%;
  height: 100%;
  border-bottom-left-radius: 4px;
  border-top-left-radius: 4px;
  border-top-right-radius: 0px;
}

.post-item.vertical .post-content {
  width: calc(30% - 12px);
  display: flex;
}

.post-item.vertical .post-content h3 {
  margin: 0;
  font-family: 'Manrope', sans-serif;
  font-weight: 500;
  font-size: 14px;
  line-height: 1.5;
  letter-spacing: 0.5%;
  text-align: center;
  text-align: end;
  color: #3B3839;

  padding: 4px 6px;
  height: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;

  mask-image: linear-gradient(to bottom, black 80%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, black 80%, transparent 100%);
  border-radius: 4px;
}


.post-item.horizontal .post-content {
  height: calc(30% - 12px);
  overflow: hidden;
}

.post-item.horizontal .post-content h3 {
  margin: 0;
  font-family: 'Manrope', sans-serif;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.5%;
  text-align: justify;
  padding-bottom: 8px;
  padding: 0px 6px;
  color: #3B3839;

  height: 100%;
  overflow: hidden;
  display: block;
  position: relative;

  mask-image: linear-gradient(to bottom, black 80%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, black 70%, transparent 100%);
  border-radius: 4px;
}

/* Details css */
.post-container {
  display: flex;
  gap: 40px;
  padding: 80px 20px 20px 20px;
  height: calc(100vh - 100px);
  user-select: none;
}

.image-grid {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  transition: all 0.3s ease-in-out;
  animation: fadeInUp 0.3s ease-in-out forwards;
  margin: auto 0px;
}

.grid-item {
  height: 100%;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  position: relative;
}

.image-grid .grid-item img {
  width: 100%;
  height: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.image-grid .grid-item::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.image-grid .grid-item:hover::after {
  opacity: 1;
}

.image-grid .grid-item:hover img {
  transform: scale(1.1);
}

.post-content {
  flex: 1;
  transition: all 0.3s ease-in-out;
  animation: fadeInUp 0.3s ease-in-out forwards;
}

.post-content-detail {
  flex: 1;
  width: 50%;
  transition: all 0.3s ease-in-out;
  animation: fadeInUp 0.3s ease-in-out forwards;
  margin: auto 40px;
}

.post-content-detail .content {
  margin: auto;
  aspect-ratio: 1/1;
  width: 50%;
  margin-bottom: 30px;
  text-align: justify;
}

.post-content-detail .content h1 {
  text-align: center;
  font-size: 24px;
}

.post-content h1 {
  font-family: 'Anton', sans-serif;
  font-weight: 400;
  font-size: 36px;
  line-height: 125%;
  letter-spacing: 0.5%;
  color: #3B3839;
}

.post-content p {
  font-family: 'Manrope', sans-serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 125%;
  text-align: justify;
  justify-self: center;
  color: #3B3839;
}

@media (max-width: 768px) {
  .menu-columns {
    flex-direction: column;
  }

  .first-letter {
    width: fit-content + 1px;
  }

  .menu-category-item a {
    display: flex;
  }

  .menu-categories {
    flex-direction: row;
    overflow-x: scroll;
    overflow-y: hidden;
    white-space: nowrap;
    scrollbar-width: none;
    user-select: none;
    gap: 5vw;
  }

  .image-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.image-popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: white;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  transition: all 0.3s ease-in-out;
  opacity: 0;
  transform: scale(0.8);
  animation: zoomIn 0.4s ease-in-out forwards;
  user-select: none;
}

@keyframes zoomIn {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }

  100% {
    opacity: 1;
    transform: scale(1);
  }
}


.image-popup .close-popup {
  position: fixed;
  top: 20px;
  right: 20px;
  cursor: pointer;
  background-color: transparent;
  border: none;
  z-index: 10;
}

.image-popup .close-popup img {
  width: 60px;
  height: 60px;
}

/*popup content*/
.popup-content {
  display: flex;
  gap: 20px;
  align-items: center;
  box-sizing: border-box;
  position: relative;
  background: white;
  overflow: hidden;
  height: 100%;
}

/* slider post content */
.popup-clone {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 20px;
  background: white;
  z-index: 5;
}

.popup-content.slide-in-left {
  animation: slideInLeft 0.5s ease forwards;
}

.popup-content.slide-in-right {
  animation: slideInRight 0.5s ease forwards;
}

.popup-content.slide-out-left {
  animation: slideOutLeft 0.5s ease forwards;
}

.popup-content.slide-out-right {
  animation: slideOutRight 0.5s ease forwards;
}

@keyframes slideInLeft {
  from {
    transform: translateX(-100%);
    opacity: 0;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideOutLeft {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-100%);
  }
}

@keyframes slideOutRight {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(100%);
  }
}

.popup-content .img-container {
  width: 50%;
  aspect-ratio: 1/1;
  padding-left: 140px;
}

.popup-description-container {
  flex: 1;
  flex-basis: 60%;
  width: 60%;
  height: 100vh;
}

.popup-description-container .content {
  margin: auto;
  width: 50%;
  aspect-ratio: 1/1;
  text-align: justify;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.popup-description-container .content h2 {
  text-align: center;
}

.img-container img {
  width: 100%;
  object-fit: cover;
  height: 100%;
}

.popup-description-container {
  height: 100%;
  color: #3B3839;
  font-size: 16px;
  line-height: 1.5;
}

.popup-description-container p {
  margin: 0;
  font-family: 'Manrope', sans-serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 125%;
  letter-spacing: 0.5%;
  text-align: justify;
  vertical-align: middle;
}

.popup-arrow {
  position: absolute;
  top: 50%;
  color: white;
  border: none;
  font-size: 24px;
  padding: 10px;
  cursor: pointer;
  z-index: 9;
  border-radius: 90%;
  background-color: transparent;
}

.popup-arrow :hover {
  transition: scale;
  scale: 1.25;
}

.popup-arrow.left-arrow {
  left: 20px;
}

.popup-arrow.right-arrow {
  right: 20px;
  rotate: 180deg;
}

@media (max-width: 768px) {
  .popup-content {
    flex-direction: column;
  }

  .popup-content .img-container,
  .popup-description-container {
    flex: 1;
    flex-basis: 90%;
    width: 90%;
  }

  .custom-space {
    display: none;
  }

  .menu-columns {
    gap: 0px;
  }

  .menu-column {
    padding-top: 16px;
    padding-left: 16px;
  }

  .posts-container {
    padding: 0px 20px 40px 20px;
    gap: 16px;
  }

  .menu-footer {
    display: none;
  }

  .popup-content .img-container {
    width: 76%;
    aspect-ratio: 1/1;
    padding-left: 0px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 75px;
  }
  
  .img-container img {
    object-fit: cover;
  }

  .popup-description-container{
    width: 100% !important;
  }

  .popup-description-container .content h2 {
    font-size: 22px;
  }
  .popup-description-container .content{
    align-items: flex-start;
  }
  .post-container{
    gap: 16px;
  }
}

@media (max-width: 675px) {
  .close-menu {
    top: 26px;
    right: 16px;
  }

  .posts-container {
    max-height: calc(100vh - 168px);
    padding-bottom: 60px;
  }

  .header {
    padding: 20px 20px;
  }

  .image-grid .grid-item {
    height: 100% !important;
    width: 100%;
    aspect-ratio: 1/1;
  }

  .post-content-detail .content {
    width: 100%;
  }

  .post-content-detail .content h1 {
    font-size: 22px;
  }

  .hero-title {
    left: 20px;
    font-size: 24px;
  }
  
  .popup-content{
    overflow: scroll;
  }
  .popup-content .img-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
  }

}

@media (max-width: 1280px) {
  .popup-description-container {
    width: 50%;
  }

  .popup-description-container .content {
    width: 70%;
  }
}

@media (max-width: 1440px) {
  .post-container {
    flex-direction: column;
  }

  .post-content-detail {
    width: 100%;
    margin: auto;
  }

  .image-grid {
    margin: auto;
  }

  .image-grid .grid-item {
    height: 244px;
  }

  .popup-description-container {
    width: 40%;
  }
}