:root {
    --accent-color: #0092ca;
    --dark-bg: #0C0C0C;
    --light-bg: #ffffff;
    --text-dark: #333;
    --text-light: #fff;
    --light-grey: #1b1b1b;
    --medium-grey: #252525;
    --dark-grey: #141414;
  }
  
  *, *::before, *::after {
    box-sizing: border-box;
  }
  
  body {
    margin: 0;
    font-family: 'Roboto', sans-serif;
    transition: background-color 0.3s, color 0.3s;
    background: url('../img/apextech3d-bg.webp') no-repeat center center;
    background-size: cover;
    background-attachment: fixed;
    overflow-x: hidden;
  }
      
  .header {
    position: fixed;
    width: 100%;
    background-color: var(--dark-bg);
    color: var(--text-light);
    z-index: 10;
    top: 0;
    padding: 10px 0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
  }
  
  .header .container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
  }
  
  .logo {
    flex: 1;
  }
  
  .logo img {
    height: 60px;
    width: auto;
    cursor: pointer;
  }
  
  .main-title {
    text-align: center;
    margin: 120px auto 0 auto;
    color: var(--accent-color);
    font-size: 2.5rem;
    font-weight: 700;
  }

  h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-color);
    margin-top: 120px;
  }
  
  h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-light);
  }
  
  h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-light);
  }
  
  .card-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
  }

  .card {
    display: flex;
    flex-direction: row;
    position: relative;
    align-items: center;
    justify-content: center;
    background-color: var(--dark-grey);
    border-radius: 15px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
    width: 100%;
    max-width: 1200px;
    margin: 10px;
    padding: 20px;
    text-align: center;
    border: 2px solid #0092ca;
    gap: 20px;
  }

.contact-button {
  padding: 5px 10px;
  background-color: var(--accent-color);
  border: 2px solid #006f9b;
  color: var(--text-light);
  font-size: 1rem;
  font-weight: 600;
  width: 100%;
  text-decoration: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.3s, transform 0.3s;
}

.contact-button i {
  color: var(--text-light);
  font-size: 18px;
  transition: color 0.3s;
  padding-right: 10px;
}

.contact-button:hover {
  transform: scale(1.15);
  border: 2px solid var(--accent-color);
  background-color: var(--light-bg) !important;
  color: var(--accent-color);
}

.contact-button:hover i {
  color: var(--accent-color);
}

.button-container {
    display: flex;
    flex-direction: column;
    position: relative;
    gap: 10px;
  }
  
  a {
    padding: 10px;
    color: var(--text-light);
    font-size: 1.5rem;
  }
  
#contact-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
  }

  /* Contact Header Styles */
.contact-header {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.contact-pic {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 10px;
  border: 2px solid var(--accent-color);
}

.contact-pic:hover {
  transform: scale(1.2);
  transition: transform 0.3s ease;
}

.card a {
  display: flex;
  align-items: flex-start;
  font-size: 1.5rem;
  color: var(--accent-color);
  text-decoration: none;
  font-weight: 600;
}

.card i {
  padding-right: 10px;
  color: var(--text-light);
}

.contact-name span {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-light);
}

.contact-name p {
  font-size: 1rem;
  color: var(--text-light);
  margin: 0;
}

.card-logo {
  width: 180px;
  height: auto;
  margin-bottom: 10px;
  animation: slideInFromRight 1s ease-in-out;
  transition: transform 0.3s ease;
  cursor: pointer;
  content: url('../img/logo.webp');
}

.card-logo:hover {
  transform: scale(1.1);
}

.light-mode .card-logo {
  content: url('../img/logo-dark.webp');
}

/* DARK/LIGHT MODES */
  body.light-mode {
    background-color: var(--light-bg);
    color: var(--text-dark);
  }
  
  body.dark-mode {
    background-color: var(--dark-grey);
    color: var(--text-light);
  }
  
  body.light-mode {
    background: url('../img/apextech3d-bg-light.webp') no-repeat center center;
    background-size: cover;
    background-attachment: fixed;
  }
  
  body.dark-mode {
    background: url('../img/apextech3d-bg.webp') no-repeat center center;
    background-size: cover;
    background-attachment: fixed;
  }
  
  body.light-mode span {
    color: var(--text-dark);
  }

  body.light-mode p {
    color: var(--text-light);
  }

  .light-mode .card {
    background-color: var(--light-bg);
    color: var(--text-dark);
    border-color: var(--accent-color);
  }
  
  .dark-mode .card {
    background-color: var(--dark-grey);
    color: var(--text-light);
  }

  .light-mode .card i {
    color: var(--text-dark);
  }
  
  body.light-mode .button:hover {
    border: 2px solid var(--accent-color);
  }

  body.light-mode .contact-name {
    color: var(--text-dark);
  }
  
  body.light-mode .contact-button i {
    color: var(--text-light);
  }
  
  body.light-mode .contact-button:hover i {
    color: var(--accent-color);
  }

/* TOGGLE SWITCH */
  .toggle-switch {
    position: relative;
    width: 100px;
    height: 50px;
    --light: #0092ca;
    --dark: #28292c;
    --link: rgb(27, 129, 112);
    --link-hover: rgb(24, 94, 82);
    display: flex;
    justify-content: end;
  }
  
  .switch-label {
    position: absolute;
    width: 50%;
    height: 25px;
    background-color: var(--dark);
    border-radius: 25px;
    cursor: pointer;
    border: 3px solid var(--dark);
    margin-top: 12px;
  }
  
  .checkbox {
    position: absolute;
    display: none;
  }
  
  .slider {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 25px;
    -webkit-transition: 0.3s;
    transition: 0.3s;
  }
  
  .checkbox:checked ~ .slider {
    background-color: var(--light);
  }
  
  .slider::before {
    content: "";
    position: absolute;
    top: 1px;
    left: 1px;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    -webkit-box-shadow: inset 12px -4px 0px 0px var(--light);
    box-shadow: inset 12px -4px 0px 0px var(--light);
    background-color: var(--dark);
    -webkit-transition: 0.3s;
    transition: 0.3s;
  }
  
  .checkbox:checked ~ .slider::before {
    -webkit-transform: translateX(24px);
    -ms-transform: translateX(24px);
    transform: translateX(24px);
    background-color: var(--dark);
    -webkit-box-shadow: none;
    box-shadow: none;
  }
  
  .toggle-switch-mobile {
    display: none;
    position: absolute;
    top: -62px;
    right: 100px;
    z-index: 13;
  }
    
  /* Profile Picture */
  .profile-pic-container {
    position: relative;
    width: 250px;
    height: 250px;
    overflow: hidden;
}

.slice {
    position: absolute;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    animation-duration: 1s;
    animation-timing-function: ease-in-out;
    animation-fill-mode: forwards;
    opacity: 0;
}

.slice:nth-child(1) {
    background-image: url('../img/SR_Slice-1.png');
    animation-name: slideInFromTop;
    animation-delay: 0.1s;
}

.slice:nth-child(2) {
    background-image: url('../img/SR_Slice-2.png');
    animation-name: slideInFromBottom;
    animation-delay: 0.2s;
}

.slice:nth-child(3) {
    background-image: url('../img/SR_Slice-3.png');
    animation-name: slideInFromTop;
    animation-delay: 0.3s;
}

.slice:nth-child(4) {
    background-image: url('../img/SR_Slice-4.png');
    animation-name: slideInFromBottom;
    animation-delay: 0.4s;
}

.slice:nth-child(5) {
    background-image: url('../img/SR_Slice-5.png');
    animation-name: slideInFromTop;
    animation-delay: 0.5s;
}

.slice:nth-child(6) {
    background-image: url('../img/SR_Slice-6.png');
    animation-name: slideInFromBottom;
    animation-delay: 0.6s;
}

.profile-pic-container:hover .slice:nth-child(1),
.profile-pic-container:hover .slice:nth-child(2),
.profile-pic-container:hover .slice:nth-child(3),
.profile-pic-container:hover .slice:nth-child(4),
.profile-pic-container:hover .slice:nth-child(5),
.profile-pic-container:hover .slice:nth-child(6) {
    background-image: url('../img/SR_Profile.webp') !important;
    animation-name: none !important;
    opacity: 1 !important;
}

/* Keyframes Definitions */
@keyframes slideInFromRight {
  0% {
      transform: translateX(150%);
      opacity: 0;
  }
  100% {
      transform: translateX(0);
      opacity: 1;
  }
}

@keyframes slideInFromTop {
  0% {
      transform: translateY(-100%);
      opacity: 0;
  }
  100% {
      transform: translateY(0);
      opacity: 1;
  }
}

@keyframes slideInFromBottom {
  0% {
      transform: translateY(100%);
      opacity: 0;
  }
  100% {
      transform: translateY(0);
      opacity: 1;
  }
}

/* Animation Classes */
.animate-slide-in-right {
  animation: slideInFromRight 1s ease-in-out forwards;
}

.animate-slide-in-top {
  animation: slideInFromTop 1s ease-in-out forwards;
}

.animate-slide-in-bottom {
  animation: slideInFromBottom 1s ease-in-out forwards;
}

/* Ensure Initial Hidden State */
.slice, .card-logo {
  opacity: 0;
}

/* Loading overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
  }
  
  .loading-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
  }
  
  .loading-content p {
    font-size: 1.5em;
    margin-top: 0.5em;
  }
  
  .spinner {
    margin: 1em auto;
    width: 50px;
    height: 50px;
    border: 5px solid #fff;
    border-top: 5px solid var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
  }
      
  @keyframes spin {
  to {
      transform: rotate(360deg);
    }
  }
    
/* FOOTER */
  .footer {
    bottom: 0;    
    position: fixed;
    left: 0;
    width: 100%;
    max-width: 100vw;
    display: flex;
    text-align: center;
    align-items: center;
    flex-direction: column;
    justify-content: center;
    padding: 10px;
    background-color: var(--dark-bg);
    color: var(--text-light);
    box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.5);
    z-index: 10;
    overflow: hidden;
    transition: height 0.3s ease;
  }
  
  .footer {
    height: 50px;
  }
  
  .footer.expanded {
    height: 160px;
  }
  
  .footer-toggle {
    position: absolute;
    top: 10px;
    right: 0;
    margin-right: 20px;
    font-size: 1.5rem;
    color: #fff;
    cursor: pointer;
    transition: transform 0.3s ease;
  }
  
  .footer.expanded .footer-toggle i {
    transform: rotate(180deg);
  }
  
  .footer-content {
    display: none;
    width: 100%;
    padding: 10px 20px;
    box-sizing: border-box;
    flex-direction: row;
    justify-content: center;
    align-items: center;
  }
  
  .footer-content button {
    margin-right: 40px;
  }
  
  .footer-content ul {
    margin-left: 40px;
  }
  
  .footer-content a {
    text-decoration: none;
    color: var(--text-light);
    font-size: 1.2rem;
    transition: color 0.3s ease;
  }
  
  .footer-content a:hover {
    color: var(--accent-color);
  }
  
  .footer.expanded .footer-content {
    display: flex;
  }
  
  .contact-button {
    background-color: #0092ca;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
  }
  
  .contact-button:hover {
    background-color: #007bb5;
  }
  
  .contact-info {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
    font-size: 0.9rem;
  }
  
  .contact-info li {
    margin-bottom: 5px;
  }
  
  .fa-chevron-up {
    right: 0;
  }

  @media (max-width: 768px) {
    .card {
      flex-direction: column;
      width: 90%;
      margin-bottom: 70px;
    }

    .card a {
      font-size: 1.2rem;
      padding: 0;
    }
    
    .file-list li {
      flex-direction: column;
      align-items: flex-start;
    }
  
    .button-container {
      width: 100%;
      justify-content: center;
    }

    .footer.footer.expanded p {
      margin: 30px 0 0;
    }
  
    .footer-toggle {
      right: 0;
      margin-right: 10px;
    }
  
    .contact-section h3 {
      margin-top: 20px;
    }
  
    .footer.expanded .footer-content {
      display: flex;
      flex-direction: column;
    }
  
    .footer-content {
      align-items: normal;
    }
  
    .footer.expanded {
      padding-top: 20px;
    }
  
    .mobile-hide {
      display: none;
    }
  
    .contact-header {
      flex-direction: column;
      align-items: center;
      margin-top: 80px;
    }
  
    .contact-info {
      position: relative;
      top: 20px;
      left: 0;
      align-items: center;
      justify-content: center;
    }
    
    .main-title {
      margin: 20px auto 0 auto;
    }

    .contact-name {
      font-size: 1.2rem;
    }

    .footer.expanded {
      height: 35%;
    }

    .contact-button:hover {
      transform: none;
    }
    
    @keyframes slideInFromRight {
      0% {
          transform: translateX(0);
          opacity: 0;
      }
      100% {
          transform: translateX(0);
          opacity: 1;
      }
    }
    
  }