@import url("https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;500;600;700&family=Noto+Serif:wght@400;500;700&display=swap");
@import url("font-awesome.min.css");
@import url("animate.css");

:root {
  --primary-color: #8CC739;
  --primary-dark: #7AB52E;
  --text-primary: #333333;
  --text-secondary: #656565;
  --text-muted: #B5B5B5;
  --border-light: #dadada;
  --background-light: #f8f9fa;
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 8px rgba(0,0,0,0.15);
  --transition: all 0.3s ease;
}

body {
  font-family: 'Open Sans', Arial, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--text-secondary);
  -webkit-font-smoothing: antialiased;
}

@media (max-width: 767px) {
  body {
    padding-right: 0;
    padding-left: 0;
  }
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--primary-dark);
  text-decoration: none;
}

a:active {
  outline: 0;
}

p {
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 1em;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Open Sans', Arial, sans-serif;
  font-weight: 600;
  line-height: 1.2;
  color: var(--text-primary);
  margin-bottom: 20px;
}

#wrapper {
  width: 100%;
  margin: 0;
  padding: 0;
}

/* --- Header --- */
header .navbar {
  margin-bottom: 0;
  min-height: 70px;
  padding: 18px 0;
  box-shadow: var(--shadow-sm);
}

.navbar-default {
  border: none;
  background-color: rgba(255, 255, 255, 0.98);
}

.navbar-brand {
  color: var(--text-primary);
  font-size: 24px;
  font-weight: 700;
  transition: var(--transition);
}

.navbar-brand:hover {
  color: var(--primary-color);
}

header .navbar-collapse ul.navbar-nav {
  float: right;
  margin-right: 0;
}

header .nav li a:hover,
header .nav li a:focus,
header .nav li.active a,
header .nav li.active a:hover {
  transition: var(--transition);
}

header .nav li.active a,
header .nav li.active a:hover {
  background: var(--primary-color) !important;
  border-radius: 5px;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

header .navbar-nav > li > a {
  padding-bottom: 6px;
  padding-top: 5px;
  margin-left: 2px;
  line-height: 30px;
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  transition: var(--transition);
}

header .navbar-nav > li > a:hover {
  transform: translateY(-1px);
}

.navbar .nav > li > a {
  color: var(--text-muted);
  text-shadow: none;
  border: none !important;
  text-align: center;
}

.navbar-default .navbar-nav > .active > a,
.navbar-default .navbar-nav > .active > a:hover,
.navbar-default .navbar-nav > .active > a:focus {
  color: #fff;
  background-color: var(--primary-color);
}

/* --- Featured Section --- */
#featured {
  width: 100%;
  position: relative;
  margin: 0;
  padding: 0;
}

#featured img {
  height: 550px;
  width: 100%;
  object-fit: cover;
  object-position: center top;
}

.description {
    animation: feature-text-anim 1.75s ease-in-out;
    z-index: 100;
    position: absolute;
    width: 100%;
    bottom: 60px;
    text-align: center;
    color: #ffffff;
}

.description p {
  font-size: 24px;
  line-height: 1.5;
  letter-spacing: 1px;
  text-shadow: 2px 2px 8px rgba(0,0,0,0.8);
}

@media (max-width: 767px) {
  .description p {
    font-size: 18px;
  }
}

.description p strong {
  text-transform: uppercase;
  font-size: 70px;
  line-height: 1;
  font-weight: 700;
  text-shadow: 3px 3px 12px rgba(0,0,0,0.9);
}

@media (max-width: 767px) {
  .description p strong {
    font-size: 30px;
  }
}

.description p:last-child > a {
  background-color: rgba(49, 52, 56, 0.9);
  border: 2px solid #fff !important;
  color: #fff;
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 500;
  text-decoration: none;
  padding: 1em 1.75em;
  display: inline-block;
  line-height: 1em;
  margin: 10px;
  border-radius: 5px;
  transition: var(--transition);
}

.description p:last-child > a:hover {
  background-color: #fff;
  color: var(--text-primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* --- Content --- */
#content {
  position: relative;
  background: #FFFFFF;
  padding: 50px 0 30px 0;
}

@media (max-width: 767px) {
  #content {
    padding: 30px 0 20px 0;
  }
}

#content img {
  max-width: 100%;
  height: auto;
  border-radius: 5px;
}

.intro {
  text-align: center;
  padding: 0 150px;
}

@media (max-width: 991px) {
  .intro {
    padding: 0 50px;
  }
}

@media (max-width: 767px) {
  .intro {
    padding: 0 20px;
  }
}

.intro strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* --- Resume Sections --- */
.resume-section {
  margin-bottom: 40px;
}

.resume-section:last-child {
  margin-bottom: 0;
}

.resume-section h3 {
  padding-bottom: 20px;
  margin: 0 0 20px 0;
  border-bottom: 2px solid var(--primary-color);
  font-weight: 600;
  position: relative;
}

.resume-section h3 i {
  margin-right: 20px;
  color: var(--primary-color);
}

.resume-item {
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 20px;
  transition: var(--transition);
}

.resume-item:last-child {
  padding-bottom: 0;
  border-bottom: none;
}

.resume-item:hover {
  transform: translateY(-2px);
  background: var(--background-light);
  padding: 20px;
  margin-left: -20px;
  margin-right: -20px;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
}

.resume-item:hover .period {
  background-color: var(--primary-color);
  transform: translateY(-2px);
}

.resume-item h4 {
  margin-bottom: 5px;
  font-weight: 600;
  color: var(--text-primary);
}

.resume-item h5 {
  color: var(--text-secondary);
  font-weight: 500;
  margin-bottom: 15px;
}

.period {
  float: right;
  padding: 11px 20px;
  background-color: var(--text-muted);
  color: #fff;
  transition: var(--transition);
  text-transform: uppercase;
  border-radius: 5px;
  font-weight: 500;
  font-size: 12px;
}

/* --- Project Sections --- */
.featured-project {
  background: var(--background-light);
  padding: 30px;
  border-radius: 8px;
  margin-bottom: 30px;
  border-left: 4px solid var(--primary-color);
}

.project-item {
  padding: 25px 0;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 25px;
}

.project-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.project-item h4 {
  margin-bottom: 10px;
  color: var(--text-primary);
}

.project-subtitle {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 0.9em;
  margin-left: 8px;
}

.github-stats {
  margin-top: 12px;
}

.github-stats iframe {
  margin-right: 8px;
}

.key-highlights {
  background: var(--background-light);
  padding: 25px;
  border-radius: 8px;
  margin: 25px 0;
  border-left: 4px solid var(--primary-color);
}

/* --- Photo Styles --- */
.speaker-photo,
.creator-photo {
  border-radius: 8px;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  margin-bottom: 10px;
}

.speaker-photo:hover,
.creator-photo:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.2);
}

.photo-caption {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  font-style: italic;
  margin-bottom: 0;
}

/* --- Contact --- */
.contact-info p:nth-child(2) {
  font-weight: 600;
  color: var(--text-primary);
}

.social-network {
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 20px;
}

@media (max-width: 767px) {
  .social-network {
    padding-bottom: 0;
    border-bottom: none;
  }
}

.btn-social-icon {
  margin: 0 5px;
  transition: var(--transition);
}

.btn-social-icon:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* --- Lists --- */
.list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-weight: 400;
}

.list li {
  margin: 5px 0 5px 10px;
  padding: 0 0 0 24px;
  position: relative;
  line-height: 1.6;
}

.list li:before {
  content: "\f0a9";
  font-family: fontAwesome;
  color: var(--primary-color);
  font-size: 14px;
  left: 5px;
  line-height: 1;
  margin: 0;
  position: absolute;
  top: 5px;
}

/* --- Footer --- */
footer {
  text-shadow: none;
  color: #A9A9A9;
  padding: 30px 0;
  margin: 20px 0 0 0;
  background: #313438;
  text-align: center;
  font-size: 12px;
}

/* --- Scroll Elements --- */
.scroll-down {
  bottom: 10px;
  color: #fff;
  cursor: pointer;
  height: 48px;
  left: 50%;
  line-height: 48px;
  margin-left: -24px;
  position: absolute;
  text-align: center;
  width: 48px;
  z-index: 100;
  transition: var(--transition);
}

.scroll-down:hover {
  color: #fff;
  transform: translateY(-2px);
}

.scroll-up {
  position: fixed;
  width: 32px;
  height: 32px;
  bottom: 0;
  right: 20px;
  background: #222;
  transition: var(--transition);
}

.scroll-up:hover {
  background: var(--primary-color);
  transform: translateY(-2px);
}

a.scroll-up {
  outline: 0;
  text-align: center;
}

a.scroll-up:hover,
a.scroll-up:active,
a.scroll-up:focus {
  opacity: 1;
  text-decoration: none;
}

a.scroll-up i {
  margin-top: 10px;
  color: #fff;
}

a.scroll-up i:hover {
  text-decoration: none;
}

/* --- Animations --- */
@keyframes feature-text-anim {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- List Improvements --- */
.list-unstyled li:hover {
  transform: translateX(3px);
  transition: var(--transition);
}

/* --- Mobile Responsive --- */
@media (max-width: 767px) {
  .navbar-nav {
    border-top: none;
    float: none;
    width: 100%;
  }

  .navbar .nav > .active > a,
  .navbar .nav > .active > a:hover {
    background: var(--primary-color);
    font-weight: 700;
    color: #fff;
  }

  .navbar-collapse.collapse {
    border: none;
    overflow: hidden;
  }

  .period {
    float: none;
    display: inline-block;
    margin-bottom: 10px;
  }

  .featured-project,
  .key-highlights {
    margin-left: -15px;
    margin-right: -15px;
    border-radius: 0;
  }

  .speaker-photo,
  .creator-photo {
    margin-bottom: 20px;
    margin-top: 20px;
  }

  .key-highlights .row,
  .resume-item .row {
    display: flex;
    flex-direction: column-reverse;
  }
}

/* --- Sticky Footer Fix --- */
html, body {
    height: 100%;
}

#wrapper {
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

.main {
    flex: 1;
}

/* Fallback for older browsers */
@supports not (display: flex) {
    html, body {
        height: 100%;
    }

    #wrapper {
        min-height: 100%;
        position: relative;
        padding-bottom: 90px; /* approximate footer height */
    }

    footer {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
    }
}
