/* =========================
   GLOBAL + SPACING SYSTEM
========================= */

:root {
  --space-xs: 6px;
  --space-sm: 12px;
  --space-md: 20px;
  --space-lg: 30px;
  --space-xl: 50px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: Arial, sans-serif;
  background: #eef2f7;
  color: #333;
  line-height: 1.5;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* =========================
   LAYOUT WIDTH
========================= */

.hero-container,
.nav-container,
section {
  max-width: 900px;
  width: 100%;
  margin: auto;
  padding-left: var(--space-md);
  padding-right: var(--space-md);
}

/* =========================
   HERO
========================= */

header {
  background: linear-gradient(135deg, #eef4ff, #ffffff);
  padding: var(--space-xl) var(--space-md) var(--space-md);
  border-bottom: 1px solid #e5e7eb;
}

.hero-container {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.hero-logo {
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: bold;
  color: white;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  border-radius: 50%;
}

.brand {
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 800;
  display: flex;
  align-items: center;
}

.brand-digi {
  background: linear-gradient(90deg, #2563eb, #1d4ed8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-hill {
  color: #1e40af;
}

.verified {
  margin-left: var(--space-xs);
}

.hero-container p {
  margin-top: var(--space-sm);
  color: #6b7280;
}

/* =========================
   NAVBAR
========================= */

nav {
  background: rgba(243, 244, 246, 0.8);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #e5e7eb;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  padding: var(--space-sm) var(--space-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.logo {
  font-size: 22px;
  font-weight: bold;
  color: #2563eb;
}

.nav-links {
  display: flex;
  gap: var(--space-md);
}

.nav-links a {
  color: #2563eb;
  text-decoration: none;
  font-weight: bold;
}

.menu-toggle {
  display: none;
}

/* =========================
   SECTIONS
========================= */

section {
  padding: var(--space-lg);
  margin: var(--space-xl) auto;
  background: white;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  scroll-margin-top: 80px;
}

h2 {
  margin-bottom: var(--space-md);
}

/* =========================
   ABOUT
========================= */

.about-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-xl);
}

.about-text {
  order: 1;
}

.about-text p {
  margin-bottom: var(--space-md);
  font-size: 0.95rem;
  color: #4b5563;
}

/* PHOTO STYLE */
.about-photo {
  order: 2; /* 🔥 pushes image to the right */
  float: none; /* remove float on desktop */
  margin: 0;
}

.about-photo img {
  width: 200px;
  border-radius: 16px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.15);
  transition: transform 0.3s ease;
}

/* subtle hover effect */
.about-photo img:hover {
  transform: scale(1.05);
}

/* =========================
   SKILLS
========================= */

.skills {
  display: flex;
  flex-wrap: wrap;
}

.skills span {
  background: #2563eb;
  color: white;
  padding: var(--space-xs) var(--space-sm);
  margin: var(--space-xs);
  border-radius: 6px;
}

/* =========================
   EXPERIENCE
========================= */

.experience-item {
  background: #f9fafb;
  padding: var(--space-md);
  border-radius: 8px;
  margin-bottom: var(--space-md);
}

/* =========================
   PROJECTS
========================= */

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-md);
}

.project {
  background: white;
  padding: var(--space-md);
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  transition: 0.2s ease;
}

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

.project img {
  border-radius: 6px;
  margin-bottom: var(--space-sm);
}

/* FEATURED PROJECT */
.project.featured {
  border: 2px solid #2563eb;
  box-shadow: 0 10px 30px rgba(37, 99, 235, 0.15);
  position: relative;
}

/* badge */
.project.featured::before {
  content: "Featured";
  position: absolute;
  top: 10px;
  left: 10px;
  background: #2563eb;
  color: white;
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 6px;
}

/* slightly stronger hover */
.project.featured:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 35px rgba(37, 99, 235, 0.25);
}

/* =========================
   HIRE BANNER
========================= */

.hire-banner {
  margin-top: var(--space-md);
  padding: var(--space-xl);
  border-radius: 20px;
  background: linear-gradient(135deg, #2563eb, #1e40af);
  color: white;
  position: relative;
  overflow: hidden;
}

.hire-banner::before {
  content: "";
  position: absolute;
  width: 300px;
  height: 300px;
  background: rgba(255,255,255,0.08);
  border-radius: 50%;
  top: -100px;
  right: -100px;
}

.hire-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-lg);
  flex-wrap: wrap;
  position: relative;
}

.hire-text h3 {
  font-size: 1.8rem;
  margin-bottom: var(--space-sm);
}

.hire-text p {
  margin-bottom: var(--space-md);
  color: #dbeafe;
}

.hire-text ul {
  list-style: none;
}

.hire-text li {
  margin-bottom: var(--space-xs);
}

.hire-text ul {
  list-style: none;
  padding: 0;
}

.hire-text li {
  position: relative;
  padding-left: 22px;
  margin-bottom: var(--space-xs);
}

.hire-text li::before {
  content: "✔";
  position: absolute;
  left: 0;
  top: 0;
  color: #93c5fd;
  font-size: 14px;
}

.hire-btn {
  display: inline-block;
  padding: 14px 26px;
  border-radius: 999px;
  background: white;
  color: #1e40af;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.25s ease;
}

.hire-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 12px 25px rgba(0,0,0,0.25);
}

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

.contact-form {
  max-width: 500px;
  margin-top: var(--space-md);
}

.form-group {
  margin-bottom: var(--space-md);
}

input,
textarea {
  width: 100%;
  padding: var(--space-sm);
  border: 1px solid #ccc;
  border-radius: 6px;
}

button {
  margin-top: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: #2563eb;
  color: white;
  border: none;
  border-radius: 6px;
}

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

footer {
  text-align: center;
  padding: var(--space-md);
  background: #f3f4f6;
}

/* =========================
   DESKTOP GRID CONTROL
========================= */

@media (min-width: 769px) {

  .projects-grid {
    grid-template-columns: repeat(3, 1fr); /* lock layout */
  }

  .hire-banner {
    grid-column: span 2; /* fills gap nicely */
    margin-top: 0; /* remove extra space */
  }

}

/* =========================
   MOBILE (FINAL CLEAN VERSION)
========================= */

@media (max-width: 768px) {

  /* SECTION SPACING */
  section {
    margin: var(--space-md) auto;
    padding: var(--space-md);
  }

  /* HERO */
  .hero-container {
    flex-direction: column;
    text-align: center;
    gap: var(--space-sm);
  }

  .brand {
    justify-content: center;
  }

  /* NAV */
  .menu-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: white;
    border-top: 1px solid #e5e7eb;
  }

  .nav-links a {
    padding: 14px;
    border-bottom: 1px solid #e5e7eb;
    text-align: center;
  }

  .nav-links.active {
    display: flex;
  }

/* ABOUT (mobile text wrap) */
.about-container {
  display: block;
  text-align: left;
  overflow: hidden; /* 🔥 THIS fixes it */
}

.about-photo {
  float: right;
  margin: var(--space-md) 0 var(--space-sm) var(--space-sm);
}

.about-photo img {
  width: 90px;
  border-radius: 12px;
}

.about-text {
  overflow: hidden; /* 🔥 fixes float issues */
}

.about-text p {
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: var(--space-sm);
}

.about-text p:last-child {
  margin-bottom: 0;
}

  /* PROJECTS */
  .projects-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }

  .project {
    padding: var(--space-md);
  }
  
  .project.featured {
  border-width: 2px;
}

  /* HIRE SECTION (tidy + consistent) */
  .hire-content {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-sm);
  }

  .hire-text p {
    margin-bottom: var(--space-sm);
  }

  .hire-btn {
    width: 100%;
    text-align: center;
  }

}