* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: black;
  color: white;
  display: flex;
  justify-content: center;
  padding: 20px;
}

.profile-container {
  width: 100%;
  max-width: 900px;
  border: 1px solid #dbdbdb;
  border-radius: 8px;
  padding: 20px;
  box-sizing: border-box;
}

.profile-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 20px;
}

.profile-pic {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 25px;
  margin-left: 30px;
  border: 0px solid #dbdbdb;
}

.profile-details {
  flex: 1;
  min-width: 200px;
}

.username {
  font-weight: normal;
  font-size: 1em;
  margin-bottom: 27px;
  margin-left: 70px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.stats {
  display: flex;
  justify-content: flex-start;
  margin-bottom: 17px;
  flex-wrap: wrap;
  gap: 43px;
  margin-left: 70px;
}

.stat {
  display: flex;
  align-items: center;
  gap: 4px;
}

.stat .count {
  font-weight: 500;
  font-size: 0.8em;
}

.stat .label {
  font-size: 0.85em;
  color: #8e8e8e;
}

.name {
  font-weight: 500;
  font-size: 0.7em;
  margin-bottom: 5px;
  margin-left: 70px;
}

.bio {
  font-weight: 400;
  background-color: #343636;
  color: white;
  margin-left: 70px;
  display: inline-block;
  padding: 5px 15px;
  font-size: 0.7em;
  border-radius: 17px;
  text-decoration: none;
}

.info-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.soulmate {
  font-weight: 400;
  color: white;
  font-size: 0.8em;
  margin-left: 70px;
  text-decoration: none;
  transition: 
    color 0.3s ease,
    transform 0.3s ease,
    text-shadow 0.3s ease;
  position: relative;
  /* padding: 4px 8px; */
}

.soulmate::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0%;
  height: 2px;
  background: #10ace0;
  transition: width 0.3s ease;
}

.soulmate:hover {
  color: #10ace0;
  transform: scale(1.08);
  text-shadow: 0 0 10px #10ace0;
}

.soulmate:hover::after {
  width: 100%;
}




.follow-btn {
  display: inline-block;
  padding: 5px 15px;
  background-color: #343636;
  color: white;
  font-weight: 500;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.80em;
  transition: background-color 0.3s ease;
}

.follow-btn:hover {
  background-color: #007cd1;
}

.highlights-pic {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid white;
  background-color: black;
  margin-right: 38px;
  margin-top: 30px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.highlights-pic:hover {
  transform: scale(1.1);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
  border-color: #fff;
  transition: ease-in;
}

.highlights-pic:last-child {
  margin-right: 0;
}

.tabs {
  display: flex;
  border-top: 1px solid #dbdbdb;
  margin-top: 80px;
  flex-wrap: wrap;
}

.tab {
  flex: 1;
  text-align: center;
  padding: 10px 0;
  cursor: pointer;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  font-size: 0.85em;
  color: #ccc;
  transition: all 0.3s ease;
}

.tab.active {
  border-bottom: 2px solid white;
  color: white;
}

.tab-content {
  margin-top: 30px;
  padding: 0 70px;
  box-sizing: border-box;
}

/* --------- Grid and Post Styles --------- */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
}

.grid-item {
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}

.grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border: 2px solid white;
  box-sizing: border-box;
  border-radius: 6px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.grid-item img:hover {
  transform: scale(1.03);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.grid-item iframe,
.grid-item video,
.grid-item img {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 10px;
}

/* -------- Base Responsive Setup -------- */
.profile-header {
  display: flex;
  flex-direction: row;
  align-items: center;
  flex-wrap: nowrap; /* Prevent line wrapping */
  overflow-x: auto; /* Allow horizontal scroll if needed */
  text-align: left;
  gap: 10px;
}

.profile-pic {
  flex-shrink: 0;
  width: 120px;
  height: 120px;
  border-radius: 50%;
}

.username,
.stats,
.name,
.bio {
  flex-shrink: 1;
  min-width: 0;
}

/* -------- Mobile Specific Adjustments -------- */


@media (max-width: 480px) {
  .profile-container {
    padding: 10px;
  }

  .profile-pic {
    width: 80px;
    height: 80px;
    margin: auto;
  }

  .username {
    font-size: 1em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .name,
  .bio {
    font-size: 0.85em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .stats {
    display: flex;
    gap: 12px;
    justify-content: space-between;
    flex-wrap: nowrap;
    font-size: 0.85em;
  }

  .stat {
    flex: 1;
    min-width: 0;
    text-align: center;
  }

  .stat .count {
    font-size: 0.9em;
  }

  .follow-btn {
    padding: 4px 8px;
    font-size: 0.75em;
    white-space: nowrap;
  }

  .tabs {
    display: flex;
    flex-direction: row;
    overflow-x: auto;
  }

  .tab {
    white-space: nowrap;
    padding: 8px 12px;
    border-bottom: none;
    border-top: 1px solid #dbdbdb;
    flex-shrink: 0;
  }

  .tab.active {
    border-top: 2px solid white;
  }

  .tab-content {
    padding: 0 10px;
  }

  .grid {
    display: grid;
    grid-template-columns: 1fr; /* force single column on mobile */
    gap: 6px;
  }

  body {
    overflow-x: hidden; /* prevent horizontal scroll */
  }
}


/* Post actions */
.post-actions {
  display: flex;
  justify-content: space-around;
  margin-top: 8px;
  flex-wrap: nowrap;
}

.post-actions button {
  background-color: red;
  border: 1px solid blue;
  padding: 4px 8px;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
  transition: background-color 0.3s ease;
  white-space: nowrap;
  font-size: 0.8em;
}

.post-actions button:hover {
  background-color: #e6e6e6;
}

/* New Effects */

/* Fade in grid on tab switch */
.tab-content > .grid {
  opacity: 0;
  animation: fadeInGrid 0.5s forwards;
}

@keyframes fadeInGrid {
  to {
    opacity: 1;
  }
}

/* Button hover scale */
.post-actions button:hover {
  transform: scale(1.1);
  background-color: #e6e6e6;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

/* Like button pulse on like */
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

.like-btn.liked {
  color: #e0245e;
  font-weight: 700;
  border-color: #e0245e;
  background-color: #ffe6ef;
  animation: pulse 0.3s ease;
}



/* ========== MODERN ICON STYLES (use with FontAwesome) ========== */
.post-actions i {
  margin-right: 6px;
}

/* ========== TOAST MESSAGE ========== */
.toast-message {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: #222;
  color: #fff;
  padding: 10px 25px;
  border-radius: 8px;
  font-size: 0.8em;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 9999;
  animation: toastFade 2s forwards;
}

@keyframes toastFade {
  0% { opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { opacity: 0; }
}

/* ========== MODAL UPGRADE ========== */
.custom-modal {
  opacity: 0;
  pointer-events: none;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.3s ease;
  z-index: 1000;
}

.custom-modal.show {
  opacity: 1;
  pointer-events: auto;
}

.custom-modal img {
  max-width: 5%;
  max-height: 5%;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

.custom-modal-close {
  position: absolute;
  top: 20px;
  right: 40px;
  font-size: 35px;
  color: #fff;
  cursor: pointer;
}

/* ========== BUTTON ENHANCEMENTS ========== */
.post-actions button i {
  margin-right: 4px;
}

/* Add pulse on 'Liked' state (already partially included) */
.liked i {
  color: #e0245e;
  animation: pulse 0.3s ease;
}

/* ========== GRID SHADOW HOVER EFFECT ========== */
.grid-item:hover {
  box-shadow: 0 8px 15px rgba(255, 255, 255, 0.1);
}

/* ========== RESPONSIVE GRID ENHANCEMENT ========== */
@media (max-width: 768px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1200px) {
  .grid {
    grid-template-columns: repeat(3, 1fr);
  }
}








/* Modal Overlay */
.welcome-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: rgba(15, 15, 35, 0.95);
  overflow: hidden;
  perspective: 1000px;
  backdrop-filter: blur(8px);
  animation: fadeIn 0.3s ease-out;
}

/* 3D Bubble/Star Container */
.bubble-container {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
  perspective: 1000px;
  transform-style: preserve-3d;
}

/* Orbiting Bubbles */
.bubble {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 22px;
  background: radial-gradient(circle at center, rgba(255, 255, 255, 0.95), rgba(173, 216, 255, 0.3) 60%, transparent 90%);
  border-radius: 50%;
  box-shadow: 
    0 0 8px rgba(173, 216, 255, 0.7),
    0 0 15px rgba(0, 180, 255, 0.5),
    inset 0 0 6px rgba(255, 255, 255, 0.8);
  animation: orbit 6s cubic-bezier(0.42, 0, 0.58, 1) infinite;
  transform-origin: 0 0;
  --orbit-radius: calc(60px + (var(--i) * 25px));
  transform: rotate(calc(var(--i) * 60deg)) translateX(var(--orbit-radius)) translateZ(calc(var(--i) * 8px));
  animation-delay: calc(var(--i) * 0.7s);
  opacity: 0.7;
  backdrop-filter: blur(1px);
}

/* Orbit Animation */
@keyframes orbit {
  0% {
    transform: rotate(0deg) translateX(var(--orbit-radius)) translateZ(calc(var(--i) * 20px));
  }
  100% {
    transform: rotate(360deg) translateX(var(--orbit-radius)) translateZ(calc(var(--i) * 20px));
  }
}

/* Modal Content */
.modal-content {
  position: relative;
  z-index: 1;
  background: linear-gradient(135deg, #ffffff, #e0f0ff);
  padding: 3rem 2.5rem;
  border-radius: 20px;
  text-align: center;
  max-width: 500px;
  width: 90%;
  box-shadow: 
    0 30px 60px rgba(0, 0, 0, 0.35),
    0 0 25px rgba(255, 255, 255, 0.5),
    inset 0 0 10px rgba(255, 255, 255, 0.6);
  animation: popIn3D 0.8s ease;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  transform-style: preserve-3d;
  backdrop-filter: blur(6px);
}

/* Optional 3D pop-in animation */
@keyframes popIn3D {
  0% {
    transform: scale(0.7) rotateX(-30deg);
    opacity: 0;
  }
  100% {
    transform: scale(1) rotateX(0deg);
    opacity: 1;
  }
}


/* Typography */
.modal-content h2 {
  font-size: 1.8rem;
  margin-bottom: 0.75rem;
  color: black;
}

.modal-content p {
  font-size: 1.1rem;
  font-weight: bold;
  color: #127c04;
  line-height: 1.6;
}

/* Button Styling */
.close-btn {
  margin-top: 2rem;
  padding: 0.75rem 1.75rem;
  background: linear-gradient(to right, #2575fc, #6a11cb);
  color: white;
  font-size: 1rem;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
  transform: translateZ(30px);
  box-shadow: 0 6px 15px rgba(38, 117, 252, 0.4);
}

.close-btn:hover {
  transform: scale(1.05) translateZ(30px);
  background: linear-gradient(to right, #1a5edc, #4a00e0);
  box-shadow: 0 8px 20px rgba(26, 94, 220, 0.5);
}

/* Fade-in Animation */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Pop-in with 3D Animation */
@keyframes popIn3D {
  0% {
    transform: perspective(800px) rotateX(360deg) scale(-0.8);
    opacity: 0;
  }
  100% {
    transform: perspective(800px) rotateX(0deg) scale(1);
    opacity: 1;
  }
}

/* Main Content Hidden Initially */
#mainContent {
  display: none;
  animation: fadeIn 0.1s ease;
}

/* Responsive */
@media (max-width: 480px) {
  .modal-content {
    padding: 2rem 1.5rem;
  }

  .modal-content h2 {
    font-size: 1.5rem;
  }

  .close-btn {
    width: 100%;
  }

  .bubble {
    width: 60px;
    height: 60px;
  }
}









    /* .hover-target {
      padding: 1em 2em;
      background: #00cfff;
      color: #fff;
      border: none;
      font-size: 1.2rem;
      margin-top: 40px;
      cursor: pointer;
      border-radius: 5px;
    }

    /* Glowing trail dot style */
    /* .cursor-dot {
      position: fixed;
      width: 6px;
      height: 6px;
      background: rgba(0, 255, 255, 0.3);
      border-radius: 50%;
      pointer-events: none;
      z-index: 9998;
      transform: translate(-50%, -50%);
      opacity: 1;
      transition: opacity 0.5s linear;
    } */

     