/* Base and Theme Variables */
:root{
  --primary-rgb: 1, 230, 76;
  --primary-color: #01E64C;
  --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);

}

html[data-bs-theme="light"] {
  --bg: #ffffff;
  --fg: #333333;
  --nav-bg: #f8f9fa;
  --nav-link: #333333;
  --highlight: #f39c12;
}
html[data-bs-theme="dark"] {
  --bg: #181818;
  --fg: #f1f1f1;
  --nav-bg: #333333;
  --nav-link: #f1f1f1;
  --highlight: #f39c12;
}

body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: Arial, sans-serif;
  transition: var(--transition);/*background-color 0.3s, color 0.3s;*/
  padding-top: 70px;
}

section {
  padding: 60px 0;
  background-color: var(--bg);
  color: var(--fg);
  transition: background-color 0.3s, color 0.3s;
}

.custom-toggler {
  width: 30px;
  height: 24px;
  position: relative;
  cursor: pointer;
}

.custom-toggler span {
  display: block;
  height: 3px;
  background-color: var(--highlight);
  margin: 5px 0;
  transition: all 0.3s ease;
}

.custom-toggler.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.custom-toggler.open span:nth-child(2) {
  opacity: 0;
}

.custom-toggler.open span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* Navbar */
.navbar {
  background: var(--nav-bg) !important;
  transition: background-color 0.3s;
}
.navbar .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
}
.navbar-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}
.nav-link {
  color: var(--nav-link) !important;
  transition: color 0.3s;
}
.nav-link:hover,
.nav-link.active {
  color: var(--highlight) !important;
}
.navbar-toggler {
  border-color: var(--highlight) !important;
}
.navbar-toggler-icon {
  background-color: var(--highlight) !important;
}
/* Ensure toggle and resume button always visible */
.theme-toggle-container,
.navbar .btn-success {
  order: 3;
  margin-left: 1rem;
}
/* .navbar-collapse {
  order: 1;
  flex: 1 1 auto;
} */

/* Theme Toggle Switch */
.theme-toggle-container {
  display: flex;
  align-items: center;
  position: relative;
  width: 50px;
  height: 26px;
}
.theme-toggle-checkbox {
  opacity: 0;
  width: 0;
  height: 0;
}
.theme-toggle-label {
  display: block;
  width: 100%;
  height: 100%;
  background: #ccc;
  border-radius: 13px;
  position: relative;
  cursor: pointer;
  transition: background 0.5s;
}
.theme-toggle-label .toggle-ball {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  background: var(--highlight);
  border-radius: 50%;
  transition: transform 0.5s ease, background 0.3s;
}
.theme-toggle-checkbox:checked + .theme-toggle-label {
  background: #ccc;
}
.theme-toggle-checkbox:checked + .theme-toggle-label .toggle-ball {
  transform: translateX(24px);
  background: var(--bg);
}

/* Home Section */
.hero {
  background: linear-gradient(to left, rgba(0,0,0,0.7), rgba(0,0,0,0.3)),
                url('https://media0.giphy.com/media/v1.Y2lkPTc5MGI3NjExMzJpdWhkZm56cjFrNW9xMzBwa2tucHlmbnRlMWIycnR4aGJtdW0xZyZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/BHNfhgU63qrks/giphy.gif') center/cover no-repeat fixed;
  height: 100vh;
  text-align: center;
  display: flex;
  align-items: center;
  padding-left: 33%;
}
.hero .container {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
}

.hero .highlight{
  color: #f39c12;
  font-size: larger;
  font-style: italic;
  font-family:'Times New Roman', Times, serif;
}

.hero h1,
.hero h3 {
  margin: 0;
}
.hero .btn-warning {
  width: 30%;
  display: block;
  margin-top: 1rem;
  align-items: center;
  background-color: #01E64C;
}

.hero .scroll-icon .mouse {
  width: 24px;
  height: 40px;
  border: 2px solid #b0afad;
  border-radius: 12px;
  margin: 0 auto;
}
.hero .scroll-icon .wheel {
  width: 4px;
  height: 8px;
  background: #b0afad;
  margin: 6px auto 0;
  border-radius: 4px;
  animation: scroll 1s infinite;
}

@keyframes scroll {
  0% { transform: translateY(0); }
  50% { transform: translateY(6px); }
  100% { transform: translateY(0); }
}

.profile-img {
  max-width: 200px;
  border: 4px solid #8ed502;
  border-radius: 50%;
  object-fit: cover;
}
.typing {
  display: inline-block;
  border-right: 2px solid var(--highlight);
  white-space: nowrap;
  animation: blink 0.75s step-end infinite;
  padding-right: 2px;
}
@keyframes blink {
  50% { border-color: transparent; }
}

/* About Section */
#about p {
  max-width: 800px;
  margin: 0 auto;
}

/* Projects Section */
.card {
  border: none;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  transition: transform 0.3s;
}
.card:hover {
  transform: translateY(-5px);
}
.card-img-top {
  border-radius: 5px 5px 0 0;
}

.card-title{
  color:#01E64C;
}

.modal-title{
  color: #f39c12;
}

/* Timeline (Resume) */
.timeline {
  list-style: none;
  padding-left: 0;
  position: relative;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 20px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--fg);
}
.timeline li {
  position: relative;
  margin-bottom: 20px;
  padding-left: 40px;
}
.timeline li span {
  font-weight: bold;
  display: block;
}
.timeline li::before {
  content: '';
  position: absolute;
  left: 13px;
  top: 5px;
  width: 14px;
  height: 14px;
  background: var(--highlight);
  border-radius: 50%;
}

/* Progress bars (Skills) */
.progress {
  height: 25px;
  background: var(--nav-bg);
  margin-bottom: 20px;
}
.progress-bar {
  background: #8ed502;
  color: #181818;
  text-align: center;
  line-height: 25px;
  font-size: larger;
  font-weight: bold;
}

/* Sections */
.section {
    padding: 120px 0;
    opacity: 0;
    transform: translateY(50px);
    transition: var(--transition);
}

.section.visible {
    opacity: 1;
    transform: translateY(0);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 3rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--primary-color);
}

/* Skills */
.skill-card {
    padding: 2rem;
    border-radius: 18px;
    transition: transform 0.3s ease;
    background: rgba(var(--primary-rgb), 0.1);
    border: 1px solid rgba(var(--primary-rgb), 0.2);
}

.skill-card:hover {
    transform: translateY(-5px);
}


/* Contact */
.contact-details {
    background: rgba(var(--primary-rgb), 0.05);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid rgba(var(--primary-rgb), 0.1);
}

.detail-item {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    margin-bottom: 2rem;
}

.detail-item i {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}



/* Footer */
footer {
  background: var(--nav-bg);
  color: var(--fg);
  padding: 20px 0;
}


/* extra */
.social-icon {
    font-size: 1.5rem;
    margin: 0 1rem;
    transition: color 0.3s ease;
    color: var(--secondary-color);
}

.social-icon:hover {
    color: var(--primary-color);
}


/* Responsive Design */
@media (max-width: 768px) {
    .hero {
        background: linear-gradient(to left, rgba(0,0,0,0.7), rgba(0,0,0,0.3)),
                url('https://media0.giphy.com/media/v1.Y2lkPTc5MGI3NjExMzJpdWhkZm56cjFrNW9xMzBwa2tucHlmbnRlMWIycnR4aGJtdW0xZyZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/BHNfhgU63qrks/giphy.gif') center/cover no-repeat fixed;
        padding-left: 5%;
        padding-right: 5%;
        text-align: center;
    }
    
    .profile-name {
        font-size: 3rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
}