/* ==== CSS RESET ==== */
html {
  scroll-behavior: smooth;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}


/* ==== VARIABLES ==== */
:root {
  --bg-dark: #0f172a;
  --bg-light: #020617;
  --primary: #38bdf8;
  --text-main: #e5e7eb;
  --text-muted: #9ca3af;
  --nav-bg: rgba(15, 23, 42, 0.9);
}

body.light {
  --bg-dark: #ede8d0;
  --bg-light: #ffffff;
  --text-main: #020617;
  --text-muted: #475569;
}


/* ==== BASE ==== */
body {
  font-family: 'Segoe UI', sans-serif;
  background: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
}

body.light {
  --bg-dark: #f6f7f3;
  --bg-light: #ffffff;
  --nav-bg: #f6f7f3;
  --text-main: #020617;
  --text-muted: #475569;
}

body.light #theme-overlay {
  background: #F5F5DC;
}

body.light .theme-toggle {
  background: #ffffff;
  border-color: #cbd5f5;
}


a {
  text-decoration: none;
  color: inherit;
}

/* ==== CONTAINER ==== */
.container {
  max-width: 1200px;
  margin: auto;
  padding: 0 1.5rem;
}

/* ==== NAVBAR ==== */
.navbar {
  background: var(--nav-bg);
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(10px);
}


.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.logo {
  font-size: 1.5rem;
  color: var(--primary);
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a:hover {
  color: var(--primary);
}

/* Right side actions */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  z-index: 10001;
}


/* ==== HAMBURGER ICON ==== */
.hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
}

.hamburger .bar {
  display: block;
  width: 24px;
  height: 2px;
  margin: 5px 0;
  background-color: var(--text-main);
  transition: all 0.3s ease;
}

/* Active state (X icon) */
.hamburger.active .bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger.active .bar:nth-child(2) {
  opacity: 0;
}

.hamburger.active .bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}


/* ==== HERO ==== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.hero h2 {
  font-size: 3rem;
}

.subtitle {
  margin-top: 1rem;
  color: var(--text-muted);
  max-width: 600px;
}

.hero-buttons {
  margin-top: 2rem;
  display: flex;
  gap: 1rem;
}

/* ==== BUTTONS ==== */
.btn {
  padding: 0.8rem 1.8rem;
  border-radius: 30px;
  font-weight: 500;
  transition: 0.3s ease;
}

.primary {
  background: var(--primary);
  color: #020617;
}

.primary:hover {
  transform: translateY(-2px);
}

.outline {
  border: 1px solid var(--primary);
}

.outline:hover {
  background: var(--primary);
  color: #020617;
}


/* ==== THEME TOGGLE BUTTON ==== */
.theme-toggle {
  background: var(--bg-light);
  border: 1px solid rgba(255,255,255,0.1);
  padding: 0.4rem 0.6rem;
  border-radius: 999px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.theme-toggle .icon {
  font-size: 1.1rem;
}

.theme-toggle:hover {
  background: var(--primary);
  transform: scale(1.05);
}



/* ==== SECTIONS ==== */
.section {
  padding: 6rem 0;
}

.fade-section {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s ease-out;
}

.fade-section.show {
  opacity: 1;
  transform: translateY(0);
}


/* ==== ABOUT ==== */
.about {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3rem;
  align-items: center;
}

.about-text h2 {
  font-size: 2.2rem;
  margin-bottom: 1rem;
}

.about-text p {
  color: var(--text-muted);
  margin-bottom: 1rem;
  text-align: justify;
}

.about-highlight {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.highlight-box {
  padding: 1.5rem;
  border-radius: 12px;
  background: var(--bg-light);
  transition: 0.3s ease;
}

.highlight-box:hover {
  transform: translateY(-5px);
}

.highlight-box h3 {
  margin-bottom: 0.5rem;
}


/* ==== THEME TRANSITION OVERLAY ==== */
#theme-overlay {
  position: fixed;
  inset: 0;
  background: #020617;
  opacity: 0;
  pointer-events: none;   
  z-index: 9000;
  transition: opacity 0.4s ease;
}


#theme-overlay.active {
  opacity: 1;
}


/* ==== SKILLS ==== */
.section-title {
  font-size: 2.2rem;
  text-align: center;
  margin-bottom: 3rem;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.skill-card {
  background: var(--bg-light);
  padding: 2rem;
  border-radius: 16px;
  transition: all 0.3s ease;
  border: 1px solid rgba(255,255,255,0.05);
}

.skill-card h3 {
  margin-bottom: 1rem;
  color: var(--primary);
}



/* Hover effect */
.skill-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.25);
}

/* Highlight IT Ops */
.skill-card.highlight {
  border: 1px solid var(--primary);
}

/* ==== SKILLS ICON GRID ==== */
.skills-icons {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 1.2rem;
}

.skill {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding: 1rem;
  border-radius: 12px;
  background: var(--bg-light);
  transition: all 0.3s ease;
}

body:not(.light) .skill {
  background: rgba(255, 255, 255, 0.03);
}

body.light .skill {
  background: #f1f5f9; /* soft light gray */
}


.skill i {
  font-size: 2rem;
}

.skill span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Hover glow */
.skill:hover {
  transform: translateY(-6px);
  background: rgba(56,189,248,0.1);
  box-shadow: 0 10px 25px rgba(56,189,248,0.25);
}

/* ==== PROJECTS ==== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.github-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.github-btn i {
  font-size: 1rem;
}


/* ====  PROJECT CARDS ==== */

.project-card.simple {
  background: var(--bg-light);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.06);
  transition: transform 0.25s ease;
}

.project-content {
  padding: 1.2rem 1.4rem 1.6rem;
}

.project-content h3 {
  margin-bottom: 0.4rem;
}

.tech-stack {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
  font-style: italic;
}

.tech-description{
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.github-btn {
  display: inline-block;
  font-size: 0.85rem;
  padding: 0.45rem 1.1rem;
  border-radius: 20px;
  border: 1px solid var(--primary);
  transition: 0.25s ease;
}

.github-btn:hover {
  background: var(--primary);
  color: #020617;
}


.project-card.simple:hover {
  transform: translateY(-4px);
}


/* ==== EDUCATION ==== */
.education-list {
  max-width: 700px;
  margin: auto;
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.education-card {
  padding-left: 1.5rem;
  border-left: 2px solid var(--primary);
  position: relative;
}

.education-card::before {
  content: '';
  position: absolute;
  left: -7px;
  top: 6px;
  width: 12px;
  height: 12px;
  background: var(--primary);
  border-radius: 50%;
}

.edu-year {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.education-card h3 {
  margin: 0.4rem 0;
}

.edu-university {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-main);
}

.edu-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 0.4rem;
}

.edu-points {
  margin-top: 0.5rem;
  padding-left: 1.2rem;
}

.edu-points li {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
  line-height: 1.5;
}

/* ==== CERTIFICATES GRID ==== */

.cert-grid {
  max-width: 900px;
  margin: auto;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.cert-item {
  background: var(--bg-light);
  padding: 1.5rem;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.06);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.cert-item h3 {
  font-size: 1rem;
}

.cert-item p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.cert-item .view-cert {
  align-self: flex-start;
  padding: 0.35rem 1rem;
  border-radius: 20px;
  border: 1px solid var(--primary);
  background: var(--bg-light);
  color: var(--text-muted);
  font-size: 0.8rem;
  cursor: pointer;
  transition: 0.25s ease;
}

.cert-item .view-cert:hover {
  background: var(--primary);
  color: #020617;
}


/* ==== CERT MODAL ==== */
.cert-modal {
  position: fixed;
  inset: 0;
  background: rgba(2,6,23,0.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.cert-modal.active {
  display: flex;
}

.cert-modal-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  animation: zoomIn 0.35s ease;
}

.cert-modal-content img {
  max-width: 70vw;     
  max-height: 80vh;    
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 12px;
}


/* Close button */
.close-modal {
  position: absolute;
  top: -10px;
  right: -10px;
  background: var(--primary);
  color: #020617;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Animation */
@keyframes zoomIn {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}



/* ==== CONTACT FORM ==== */

.contact-form {
  max-width: 500px;
  margin: auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-form input,
.contact-form textarea {
  padding: 0.8rem 1rem;
  border-radius: 10px;
  border: 1px solid;
  outline: none;
  background: var(--bg-light);
  color: var(--text-main);
  font-size: 0.9rem;
}

.contact-form textarea {
  resize: none;
}

.form-status {
  font-size: 0.85rem;
  margin-top: 0.5rem;
}



/* ==== FOOTER ==== */

.footer {
  padding: 2rem 0;
  margin-top: 4rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.footer p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

