/* ==========================================================================
   HAMZA IHSAN - PERSONAL PORTFOLIO
   Design Language Inspired by ericwadkins.com
   ========================================================================== */

:root {
  --primary: #1d809f;
  --primary-hover: #155d74;
  --primary-dark: #124353;
  --secondary: #ecb807;
  --secondary-hover: #d2a406;
  --dark: #212529;
  --dark-navy: #16202c;
  --dark-panel: #1e2b3a;
  --light-bg: #edeeef;
  --light-card: #f8fafc;
  --text-main: #334155;
  --text-muted: #64748b;
  --text-faded: rgba(255, 255, 255, 0.85);
  --border-subtle: rgba(255, 255, 255, 0.12);
  --font-heading: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Source Sans Pro', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-serif: 'Droid Serif', 'Roboto Slab', Georgia, serif;
  --font-mono: 'Fira Code', Menlo, Monaco, Consolas, monospace;
  --transition-speed: 0.25s;
}

/* ---------------- Global Reset & Typography ---------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  color: var(--text-main);
  background-color: #ffffff;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: inherit;
  line-height: 1.3;
}

p.lead {
  font-size: 1.15rem;
  font-weight: 400;
  line-height: 1.7;
}

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

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

.text-white { color: #ffffff !important; }
.text-secondary { color: var(--secondary) !important; }
.text-faded { color: var(--text-faded) !important; }
.text-primary { color: var(--primary) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-center { text-align: center !important; }
.text-uppercase { text-transform: uppercase !important; }

/* ---------------- Layout & Container ---------------- */
.container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin-left: -15px;
  margin-right: -15px;
}

[class*="col-"] {
  position: relative;
  width: 100%;
  padding-left: 15px;
  padding-right: 15px;
}

.col-12 { flex: 0 0 100%; max-width: 100%; }
.col-md-4 { flex: 0 0 100%; max-width: 100%; }
.col-md-5 { flex: 0 0 100%; max-width: 100%; }
.col-md-6 { flex: 0 0 100%; max-width: 100%; }
.col-md-7 { flex: 0 0 100%; max-width: 100%; }
.col-md-8 { flex: 0 0 100%; max-width: 100%; }
.col-lg-3 { flex: 0 0 100%; max-width: 100%; }
.col-lg-4 { flex: 0 0 100%; max-width: 100%; }
.col-lg-6 { flex: 0 0 100%; max-width: 100%; }
.col-lg-8 { flex: 0 0 100%; max-width: 100%; }
.col-lg-10 { flex: 0 0 100%; max-width: 100%; }
.col-lg-12 { flex: 0 0 100%; max-width: 100%; }

@media (min-width: 768px) {
  .col-md-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
  .col-md-5 { flex: 0 0 41.666667%; max-width: 41.666667%; }
  .col-md-6 { flex: 0 0 50%; max-width: 50%; }
  .col-md-7 { flex: 0 0 58.333333%; max-width: 58.333333%; }
  .col-md-8 { flex: 0 0 66.666667%; max-width: 66.666667%; }
}

@media (min-width: 992px) {
  .col-lg-3 { flex: 0 0 25%; max-width: 25%; }
  .col-lg-4 { flex: 0 0 33.333333%; max-width: 33.333333%; }
  .col-lg-6 { flex: 0 0 50%; max-width: 50%; }
  .col-lg-8 { flex: 0 0 66.666667%; max-width: 66.666667%; }
  .col-lg-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
}

.mx-auto { margin-left: auto !important; margin-right: auto !important; }
.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: 0.25rem !important; }
.mb-2 { margin-bottom: 0.5rem !important; }
.mb-3 { margin-bottom: 1rem !important; }
.mb-4 { margin-bottom: 1.5rem !important; }
.mb-5 { margin-bottom: 3rem !important; }
.mt-2 { margin-top: 0.5rem !important; }
.mt-3 { margin-top: 1rem !important; }
.mt-4 { margin-top: 1.5rem !important; }
.mt-5 { margin-top: 3rem !important; }
.mr-1 { margin-right: 0.25rem !important; }
.mr-2 { margin-right: 0.5rem !important; }
.mr-3 { margin-right: 1rem !important; }
.ml-1 { margin-left: 0.25rem !important; }
.ml-2 { margin-left: 0.5rem !important; }
.ml-3 { margin-left: 1rem !important; }

/* ---------------- Content Sections ---------------- */
.content-section {
  padding-top: 5rem;
  padding-bottom: 5rem;
  position: relative;
}

.content-section-heading {
  margin-bottom: 3rem;
  text-align: center;
}

.content-section-heading h2 {
  font-size: 2.75rem;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.content-section-heading h3 {
  font-size: 1.15rem;
  font-family: var(--font-heading);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 2px;
  margin-bottom: 0.5rem;
}

.bg-primary { background-color: var(--primary) !important; }
.bg-dark { background-color: var(--dark) !important; }
.bg-dark-navy { background-color: var(--dark-navy) !important; }
.bg-light { background-color: var(--light-bg) !important; }

/* ---------------- Navigation ---------------- */
#mainNav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1030;
  padding: 1.25rem 0;
  transition: all 0.35s ease;
  background-color: transparent;
}

#mainNav.navbar-shrink {
  padding: 0.75rem 0;
  background-color: rgba(22, 32, 44, 0.98);
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

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

.navbar-brand {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff !important;
  letter-spacing: 1px;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.navbar-brand:hover {
  text-decoration: none;
  color: var(--secondary) !important;
}

.navbar-brand .brand-badge {
  background: var(--secondary);
  color: #111;
  font-size: 0.7rem;
  padding: 2px 7px;
  border-radius: 0;
  font-weight: 800;
}

.navbar-toggler {
  display: none;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  padding: 0.5rem 0.85rem;
  border-radius: 0;
  font-size: 0.9rem;
  font-family: var(--font-heading);
  font-weight: 700;
  cursor: pointer;
}

.navbar-menu {
  display: flex;
  list-style: none;
  align-items: center;
  gap: 1.5rem;
}

.nav-link {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.85) !important;
  text-decoration: none;
  position: relative;
  padding: 0.4rem 0.2rem;
  transition: color var(--transition-speed) ease;
}

.nav-link:hover, .nav-link.active {
  color: var(--secondary) !important;
  text-decoration: none;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--secondary);
}

.nav-btn-resume {
  background: var(--secondary);
  color: #111827 !important;
  padding: 0.45rem 1rem !important;
  border-radius: 0;
  font-weight: 800 !important;
  box-shadow: 0 2px 8px rgba(236, 184, 7, 0.35);
  transition: transform var(--transition-speed) ease, background var(--transition-speed) ease !important;
}

.nav-btn-resume:hover {
  background: #ffffff !important;
  color: #111827 !important;
  transform: translateY(-2px);
}

@media (max-width: 991px) {
  .navbar-toggler { display: block; }
  .navbar-menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(22, 32, 44, 0.98);
    padding: 1.5rem;
    gap: 1rem;
    box-shadow: 0 10px 25px rgba(0,0,0,0.4);
  }
  .navbar-menu.show { display: flex; }
}

/* ---------------- Masthead / Hero ---------------- */
header.masthead {
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 8rem;
  padding-bottom: 5rem;
  background: linear-gradient(135deg, #111827 0%, #16202c 50%, #0f172a 100%);
  color: #ffffff;
  text-align: center;
}

header.masthead::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 50% 30%, rgba(29, 128, 159, 0.25) 0%, transparent 70%);
  pointer-events: none;
}

.masthead-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
}

.profile-avatar-wrap {
  position: relative;
  display: inline-block;
  margin-bottom: 2rem;
}

.profile-avatar-wrap img {
  width: 240px;
  height: 240px;
  object-fit: cover;
  border-radius: 50% !important;
  border: 6px solid #ffffff;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.45);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.profile-avatar-wrap img:hover {
  transform: scale(1.03);
  box-shadow: 0 16px 45px rgba(29, 128, 159, 0.5);
}

/* Terminal Status Bar & Tech Badge */
.terminal-status-bar {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: rgba(2, 6, 23, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(56, 189, 248, 0.4);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4), 0 0 16px rgba(56, 189, 248, 0.18);
  border-radius: 0;
  padding: 0.45rem 1.25rem;
  margin-top: 1.25rem;
  margin-bottom: 1.5rem;
  transition: all 0.3s ease;
}

.terminal-status-bar:hover {
  border-color: #38bdf8;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5), 0 0 25px rgba(56, 189, 248, 0.3);
  transform: translateY(-2px);
}

.terminal-dot {
  width: 10px;
  height: 10px;
  background-color: #22c55e;
  border-radius: 0;
  display: inline-block;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
  animation: techPulseDot 2s infinite cubic-bezier(0.66, 0, 0, 1);
}

@keyframes techPulseDot {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 8px rgba(34, 197, 94, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
  }
}

.terminal-code {
  font-family: var(--font-mono);
  font-size: 0.88rem;
  color: #e2e8f0;
  letter-spacing: 0.5px;
}

.terminal-prompt {
  color: #38bdf8;
  font-weight: 800;
  margin-right: 4px;
}

.terminal-flag {
  color: #94a3b8;
  font-weight: 600;
  margin-left: 6px;
}

.terminal-role {
  color: #38bdf8;
  font-weight: 700;
}

.terminal-feature {
  color: #c084fc;
  font-weight: 700;
}

.terminal-ready {
  color: #4ade80;
  font-weight: 700;
}

.masthead h1 {
  font-size: 3.75rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
  letter-spacing: -1px;
  text-shadow: 0 3px 20px rgba(0, 0, 0, 0.4);
}

.masthead h3 {
  font-family: var(--font-body);
  font-size: 1.4rem;
  font-weight: 400;
  color: #cbd5e1;
  margin-bottom: 2.5rem;
  line-height: 1.5;
}

.masthead h3 em {
  font-style: italic;
}

.masthead-badge-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin-bottom: 2.5rem;
}

.masthead-badge {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  padding: 0.35rem 0.85rem;
  border-radius: 0;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: #93c5fd;
}

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-block;
  font-family: var(--font-heading);
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
  user-select: none;
  border: 1px solid transparent;
  padding: 0.75rem 1.75rem;
  font-size: 0.95rem;
  line-height: 1.5;
  border-radius: 0;
  text-decoration: none !important;
  cursor: pointer;
  transition: all var(--transition-speed) ease;
}

.btn-xl {
  padding: 1rem 2.25rem;
  font-size: 1.05rem;
  letter-spacing: 0.5px;
  border-radius: 0;
}

.btn-light {
  background-color: #ffffff;
  color: var(--dark) !important;
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

.btn-light:hover {
  background-color: #f1f5f9;
  color: var(--primary) !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.25);
}

.btn-dark {
  background-color: var(--dark-navy);
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-dark:hover {
  background-color: #0f172a;
  color: var(--secondary) !important;
  border-color: var(--secondary);
  transform: translateY(-2px);
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff !important;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(29, 128, 159, 0.4);
}

.btn-secondary {
  background-color: var(--secondary);
  color: #111827 !important;
  font-weight: 800;
}

.btn-secondary:hover {
  background-color: var(--secondary-hover);
  transform: translateY(-2px);
}

.about-btn {
  margin: 0.35rem 0.45rem;
}

/* ---------------- Services Inquiry Callout Box ---------------- */
.services-cta-box {
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 0;
  padding: 1.5rem 2rem;
  max-width: 860px;
  margin: 2.25rem auto 0 auto;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4), 0 0 25px rgba(56, 189, 248, 0.15);
  text-align: left;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.services-cta-box:hover {
  transform: translateY(-3px);
  border-color: rgba(56, 189, 248, 0.65);
}

.services-cta-content {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

@media (max-width: 768px) {
  .services-cta-content {
    flex-direction: column;
    text-align: center;
  }
  .services-cta-box {
    text-align: center;
    padding: 1.5rem;
  }
}

.services-cta-tag {
  display: inline-block;
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.25rem 0.65rem;
  border-radius: 0;
  margin-bottom: 0.5rem;
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.services-cta-title {
  color: #ffffff;
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 0.35rem;
  line-height: 1.3;
}

.services-cta-desc {
  color: #94a3b8;
  font-size: 0.95rem;
  margin-bottom: 0;
  line-height: 1.5;
}

.services-cta-btn {
  white-space: nowrap;
  flex-shrink: 0;
  padding: 0.85rem 1.6rem;
  font-size: 0.95rem;
  border-radius: 0;
}

/* ---------------- Clients / Affiliations Banner ---------------- */
.clients-section {
  background-color: #ffffff;
  padding: 2.5rem 0;
  border-bottom: 1px solid #e2e8f0;
}

.clients-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}

.client-item {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.85;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.client-item:hover {
  opacity: 1;
  transform: translateY(-3px);
}

.client-item img {
  height: 48px;
  width: auto;
  max-width: 170px;
  object-fit: contain;
}

/* Biztek Apps rounded badge */
.client-item-biztek {
  background: #000000 !important;
  border-radius: 50% !important;
  padding: 6px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35) !important;
}

.client-item-biztek img {
  height: 42px !important;
  border-radius: 50% !important;
}

/* Infinity App Systems rounded badge */
.client-item-infinity {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 50% !important;
  padding: 6px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

.client-item-infinity img {
  height: 42px !important;
  border-radius: 50% !important;
}

/* Matrix Solutions logo badge */
.client-item-matrix img {
  height: 54px !important;
  border-radius: 8px !important;
}

/* ---------------- About Section ---------------- */
#about {
  background-color: var(--light-bg);
}

.about-avatar-card {
  text-align: center;
  margin-bottom: 2rem;
}

.about-avatar-card img {
  width: 280px;
  height: 280px;
  object-fit: cover;
  border-radius: 50% !important;
  border: 8px solid #ffffff;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.social-buttons {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50% !important;
  background-color: var(--dark-navy);
  color: #ffffff !important;
  font-size: 1.15rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  transition: all var(--transition-speed) ease;
}

.social-btn:hover {
  background-color: var(--primary);
  color: #ffffff !important;
  transform: translateY(-3px);
  text-decoration: none;
}

.about-bio h4 {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 0.25rem;
  color: var(--dark);
}

.about-bio .lead-role {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 1.25rem;
}

.about-bio p {
  font-size: 1.05rem;
  color: #475569;
  margin-bottom: 1.25rem;
}

.edu-list {
  list-style-type: none;
  margin-top: 1rem;
  margin-bottom: 1.5rem;
}

.edu-list li {
  position: relative;
  padding-left: 1.75rem;
  margin-bottom: 0.75rem;
  font-size: 1.05rem;
}

.edu-list li::before {
  content: '▪';
  position: absolute;
  left: 0;
  color: var(--primary);
  font-size: 1.5rem;
  line-height: 1;
}

/* ---------------- Skills Section Compact Grid ---------------- */
/* ---------------- Skills Section Compact Grid (High-Tech Styling & Animations) ---------------- */
#skills {
  background: radial-gradient(circle at 15% 15%, rgba(56, 189, 248, 0.08) 0%, transparent 45%),
              radial-gradient(circle at 85% 85%, rgba(238, 169, 89, 0.08) 0%, transparent 45%),
              #123246;
  color: #ffffff;
  padding-top: 5rem;
  padding-bottom: 5rem;
  position: relative;
}

.skills-intro {
  max-width: 820px;
  margin: 0 auto 3rem auto;
}

.skills-category-block {
  margin-bottom: 2.75rem;
}

.skills-category-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--secondary);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
}

.skills-category-title i {
  color: #38bdf8;
  filter: drop-shadow(0 0 6px rgba(56, 189, 248, 0.5));
}

.skills-category-title::after {
  content: '';
  flex-grow: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(56, 189, 248, 0.5) 0%, rgba(255, 255, 255, 0.12) 100%);
}

/* Borderless Skills Grid (Enlarged Circular Logos, Label Below) */
.skills-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 1.75rem 1.75rem;
  padding: 0.5rem 0 1rem 0;
  background: transparent !important;
  border: none !important;
}

@media (max-width: 768px) {
  .skills-grid {
    justify-content: center;
    gap: 1.25rem 1rem;
  }
}

.skill-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  width: 92px;
  text-align: center;
  background: transparent !important;
  border: none !important;
  cursor: default;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 0;
}

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

/* All logos are strictly round / circular emblems */
.skill-logo-wrap {
  width: 56px;
  height: 56px;
  min-width: 56px;
  border-radius: 50% !important;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  overflow: hidden !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  border: 2px solid rgba(255, 255, 255, 0.15);
  transition: all 0.25s ease;
}

.skill-logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 50% !important;
  display: block;
}

.skill-item:hover .skill-logo-wrap {
  transform: scale(1.1);
  border-color: #38bdf8;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.65), 0 6px 14px rgba(0, 0, 0, 0.4);
}

.skill-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #e2e8f0;
  letter-spacing: 0.2px;
  margin-top: 0.65rem;
  line-height: 1.25;
  text-align: center;
  transition: color 0.2s ease;
  word-break: break-word;
}

.skill-item:hover .skill-label {
  color: #38bdf8;
}

/* ---------------- Projects Section - Clean, Stylish, Coverless ---------------- */
#projects {
  background-color: #ffffff;
  padding-top: 5rem;
  padding-bottom: 5rem;
}

.projects-stylish-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 1.75rem;
  margin-top: 2.5rem;
}

@media (max-width: 767px) {
  .projects-stylish-grid {
    grid-template-columns: 1fr;
  }
}

.project-card-stylish {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0;
  padding: 1.75rem 1.6rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.project-card-stylish::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary) 0%, var(--secondary) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-card-stylish:hover {
  transform: translateY(-5px);
  border-color: #cbd5e1;
  box-shadow: 0 16px 35px rgba(15, 23, 42, 0.1);
}

.project-card-stylish:hover::before {
  opacity: 1;
}

.project-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 0.75rem;
}

.project-card-title-wrap {
  flex-grow: 1;
}

.project-card-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--dark);
  line-height: 1.3;
  margin-bottom: 0.35rem;
}

.project-card-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--primary);
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  padding: 0.2rem 0.6rem;
  border-radius: 0;
}

.project-card-badge.ai {
  color: #7c3aed;
  background: #f5f3ff;
  border-color: #ddd6fe;
}

.project-card-badge.systems {
  color: #ea580c;
  background: #fff7ed;
  border-color: #ffedd5;
}

.project-card-badge.web {
  color: #0284c7;
  background: #f0f9ff;
  border-color: #bae6fd;
}

.project-card-badge.mobile {
  color: #059669;
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.project-card-github-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #0f172a;
  color: #ffffff !important;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.45rem 0.85rem;
  border-radius: 0;
  text-decoration: none !important;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.project-card-github-btn:hover {
  background: var(--primary);
  transform: translateY(-2px);
}

.project-card-tagline {
  font-size: 0.95rem;
  font-style: italic;
  font-family: var(--font-serif);
  color: var(--primary-dark);
  margin-bottom: 0.85rem;
  line-height: 1.45;
}

.project-card-desc {
  font-size: 0.96rem;
  color: #475569;
  line-height: 1.65;
  margin-bottom: 1.35rem;
  flex-grow: 1;
}

.project-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.project-card-tag {
  background: #f1f5f9;
  color: #334155;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 0;
  border: 1px solid #e2e8f0;
}

.project-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #f1f5f9;
  padding-top: 1rem;
  margin-top: auto;
}

.project-card-modal-link {
  font-family: var(--font-heading);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none !important;
  cursor: pointer;
}

.project-card-modal-link:hover {
  color: var(--primary-hover);
  text-decoration: underline !important;
}

/* ---------------- Timeline / Experience Section (Fixed Logo Overlay) ---------------- */
#timeline {
  background-color: #ffffff;
}

.timeline {
  position: relative;
  padding: 0;
  list-style: none;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 40px;
  width: 2px;
  margin-left: -1px;
  background-color: #cbd5e1;
}

.timeline > li {
  position: relative;
  min-height: 70px;
  margin-bottom: 50px;
}

.timeline > li::after,
.timeline > li::before {
  display: table;
  content: " ";
}

.timeline > li::after {
  clear: both;
}

/* Fixed Emblem Circle: perfectly inset with border & padding, zero overflow */
.timeline .timeline-image {
  position: absolute;
  left: 0;
  z-index: 10;
  width: 80px;
  height: 80px;
  border: 5px solid #ffffff;
  border-radius: 50% !important;
  background-color: #16202c;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 6px; /* Inset padding completely prevents logo from touching or clipping outside the white border */
  box-sizing: border-box;
}

.timeline .timeline-image img {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain; /* Enforces that the logo never stretches or clips */
  border-radius: 50% !important;
  display: block;
}

.timeline .timeline-panel {
  position: relative;
  float: right;
  width: 100%;
  padding: 0 20px 0 110px;
  text-align: left;
}

.timeline .timeline-heading h5 {
  font-size: 0.95rem;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.timeline .timeline-heading .subheading {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 0.75rem;
}

.timeline .timeline-body p {
  font-size: 1rem;
  color: #475569;
  line-height: 1.65;
}

@media (min-width: 768px) {
  .timeline::before {
    left: 50%;
  }

  .timeline > li {
    min-height: 100px;
    margin-bottom: 80px;
  }

  .timeline .timeline-image {
    left: 50%;
    width: 90px;
    height: 90px;
    margin-left: -45px;
    padding: 8px;
  }

  .timeline .timeline-panel {
    float: left;
    width: 41%;
    padding: 0 30px 20px 20px;
    text-align: right;
  }

  .timeline > li.timeline-inverted > .timeline-panel {
    float: right;
    padding: 0 20px 20px 30px;
    text-align: left;
  }
}

/* ---------------- Contact Section (Stylish Modern Card) ---------------- */
#contact {
  background: linear-gradient(135deg, #0b1120 0%, #0f172a 50%, #16202c 100%);
  color: #ffffff;
  padding-top: 6rem;
  padding-bottom: 6rem;
  position: relative;
}

.contact-badge-subtext {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.3);
  padding: 0.35rem 1rem;
  border-radius: 0;
  margin-bottom: 1.25rem;
  letter-spacing: 0.5px;
}

.contact-direct-links {
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
  color: #94a3b8;
}

.contact-direct-links a {
  color: var(--secondary);
  font-weight: 700;
  transition: color 0.2s ease;
}

.contact-direct-links a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.contact-card-stylish {
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0;
  padding: 1.85rem 2rem;
  max-width: 580px;
  margin: 0 auto;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 25px rgba(56, 189, 248, 0.08);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.contact-card-stylish:hover {
  border-color: rgba(56, 189, 248, 0.35);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6), 0 0 30px rgba(56, 189, 248, 0.12);
}

.contact-label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.84rem;
  font-weight: 700;
  color: #cbd5e1;
  margin-bottom: 0.35rem;
  letter-spacing: 0.3px;
}

.form-group {
  margin-bottom: 0.95rem;
  text-align: left;
}

.contact-input-styled {
  width: 100%;
  background: rgba(2, 6, 23, 0.8) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  color: #ffffff !important;
  border-radius: 0 !important;
  padding: 0.65rem 0.95rem !important;
  font-size: 0.92rem !important;
  font-family: var(--font-body);
  transition: all 0.25s ease !important;
}

.contact-input-styled::placeholder {
  color: #64748b !important;
  font-size: 0.88rem !important;
}

.contact-input-styled:focus {
  outline: none !important;
  border-color: #38bdf8 !important;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.25) !important;
  background: rgba(2, 6, 23, 0.95) !important;
}

textarea.contact-input-styled {
  min-height: 95px;
  resize: vertical;
}

.contact-submit-btn {
  background: var(--secondary) !important;
  color: #0f172a !important;
  font-weight: 800 !important;
  font-size: 0.98rem !important;
  padding: 0.75rem 2.2rem !important;
  border-radius: 0 !important;
  box-shadow: 0 6px 20px rgba(238, 169, 89, 0.35) !important;
  transition: all 0.25s ease !important;
  border: none !important;
}

.contact-submit-btn:hover {
  background: var(--secondary-hover) !important;
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(238, 169, 89, 0.5) !important;
}

.form-status {
  padding: 1rem 1.25rem;
  border-radius: 0;
  margin-bottom: 1.5rem;
  display: none;
  font-weight: 600;
  text-align: left;
  line-height: 1.5;
}

.form-status.success {
  display: block;
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid #22c55e;
  color: #86efac;
}

.form-status.error {
  display: block;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid #ef4444;
  color: #fca5a5;
}

/* ---------------- Modals ---------------- */
.portfolio-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1050;
  display: none;
  overflow-x: hidden;
  overflow-y: auto;
  background-color: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  padding: 2rem 1rem;
}

.portfolio-modal.show {
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-dialog {
  position: relative;
  width: 100%;
  max-width: 860px;
  margin: auto;
}

.modal-content {
  position: relative;
  background-color: #ffffff;
  border-radius: 0;
  padding: 2.75rem 2.25rem;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
  color: var(--text-main);
}

.close-modal {
  position: absolute;
  top: 25px;
  right: 25px;
  width: 44px;
  height: 44px;
  background: #f1f5f9;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-speed) ease;
  font-size: 1.25rem;
  color: #64748b;
  border: none;
}

.close-modal:hover {
  background: #e2e8f0;
  color: #0f172a;
  transform: rotate(90deg);
}

.modal-body h2 {
  font-size: 2.3rem;
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 0.5rem;
}

.modal-body .item-intro {
  font-size: 1.15rem;
  font-style: italic;
  font-family: var(--font-serif);
  color: var(--primary-dark);
  margin-bottom: 1.75rem;
}

.modal-body p.lead {
  font-size: 1.08rem;
  line-height: 1.8;
  color: #334155;
  margin-bottom: 1.25rem;
}

.modal-tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
  margin-bottom: 2rem;
}

.modal-tech-badge {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #1e293b;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.35rem 0.85rem;
  border-radius: 0;
}

.modal-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e2e8f0;
}

/* ---------------- Resume Modal ---------------- */
.resume-modal-dialog {
  max-width: 1000px;
}

.resume-iframe-wrap {
  width: 100%;
  height: 650px;
  border: 1px solid #cbd5e1;
  border-radius: 0;
  margin-top: 1.5rem;
  overflow: hidden;
}

.resume-iframe-wrap iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* ---------------- Footer ---------------- */
footer.footer {
  background-color: var(--dark-navy);
  color: #94a3b8;
  padding: 3.5rem 0 2.5rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.footer-links {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  color: #94a3b8;
  font-weight: 600;
  font-size: 0.95rem;
}

.footer-links a:hover {
  color: #ffffff;
}

/* ---------------- Scroll to Top ---------------- */
.scroll-to-top {
  position: fixed;
  right: 25px;
  bottom: 25px;
  width: 48px;
  height: 48px;
  background-color: rgba(22, 32, 44, 0.85);
  backdrop-filter: blur(5px);
  color: #ffffff !important;
  border-radius: 50% !important;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: all var(--transition-speed) ease;
  font-size: 1.25rem;
}

.scroll-to-top:hover {
  background-color: var(--primary);
  transform: translateY(-3px);
  text-decoration: none;
}

.scroll-to-top.visible {
  display: flex;
}
