/* ==========================================================================
   1. Global Reset & Base Styles
   ========================================================================== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, sans-serif;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px; /* Offset for sticky header */
}

body {
  background-color: #0f172a;
  color: #d7e1f0;
  line-height: 1.6;
}

.section-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

h2 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
  color: #ffffff;
  padding-left: 0; /* Direct flush alignment with grid left edge */
}

/* ==========================================================================
   2. Glassmorphism Navigation Bar
   ========================================================================== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1rem 2rem;
}

.nav-container {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-size: 1.3rem;
  font-weight: 700;
  color: #ffffff;
  text-decoration: none;
}

.logo span {
  color: #2563eb;
}

.nav-links a {
  color: #94a3b8;
  text-decoration: none;
  margin: 0 1rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: #ffffff;
}

/* Header Top-Right CTA */
.btn-cta {
  background-color: transparent;
  color: #38bdf8;
  border: 1px solid #38bdf8;
  padding: 0.45rem 1rem;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-cta:hover {
  background-color: #38bdf8;
  color: #0f172a;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.4);
}

/* ==========================================================================
   3. Hero & About Sections
   ========================================================================== */
.hero {
  text-align: center;
  padding: 5rem 1rem;
  background: linear-gradient(135deg, #1e293b, #0f172a);
  color: #ffffff;
}

.hero h1 { 
  font-size: 2.5rem; 
  margin-bottom: 0.5rem; 
}

.hero p.tagline {
  color: #38bdf8;
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.hero p.bio { 
  color: #94a3b8; 
  font-size: 1.05rem; 
  max-width: 600px;
  margin: 0 auto 1.5rem auto;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.about-section {
  padding: 4rem 0;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
}

@media (max-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   4. Projects Section & Card Components
   ========================================================================== */
.projects-section {
  padding: 4rem 0;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.project-card {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3);
  border-color: rgba(37, 99, 235, 0.4);
}

.card-thumbnail {
  width: 100%;
  height: 180px;
  overflow: hidden;
  background: #0f172a;
}

.card-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.project-card:hover .card-thumbnail img {
  transform: scale(1.05);
}

/* Placeholder Icon Style for 3rd Card */
.placeholder-thumbnail {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.placeholder-thumbnail i {
  font-size: 2.8rem;
  color: #38bdf8;
  opacity: 0.85;
  filter: drop-shadow(0 0 8px rgba(56, 189, 248, 0.3));
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.project-card:hover .placeholder-thumbnail i {
  transform: scale(1.1);
  opacity: 1;
}

.card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  justify-content: space-between;
}

.project-card h3 { 
  margin-bottom: 0.5rem; 
  color: #ffffff;
}

.project-card p { 
  font-size: 0.95rem; 
  color: #94a3b8; 
  margin-bottom: 1rem; 
}

/* Badges */
.skill-badges, .tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.skill-badge, .tech-tags span {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  padding: 0.35rem 0.75rem;
  border-radius: 20px;
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

/* Action Buttons */
.card-links {
  display: flex;
  gap: 0.75rem;
}

.btn {
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 500;
  text-align: center;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.btn.primary { 
  background-color: #2563eb; 
  color: #ffffff; 
}

.btn.primary:hover { 
  background-color: #1d4ed8; 
  transform: translateY(-1px);
}

.btn.secondary { 
  background-color: rgba(255, 255, 255, 0.1); 
  color: #ffffff; 
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn.secondary:hover { 
  background-color: rgba(255, 255, 255, 0.2); 
}

.btn.disabled { 
  background-color: #334155; 
  color: #64748b; 
  cursor: not-allowed; 
}

/* ==========================================================================
   5. Contact Section & Footer
   ========================================================================== */
.contact-section {
  padding: 4rem 0;
}

.contact-links {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.75rem 1.25rem;
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #ffffff;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.2s ease;
}

.contact-card:hover {
  background: #2563eb;
  transform: translateY(-2px);
}

footer {
  text-align: center;
  padding: 2rem 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #64748b;
  font-size: 0.9rem;
}
