/* ==========================================================================
   Modern Portfolio Stylesheet - Light Theme ✨
   ========================================================================== */

/* --- Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Playfair+Display:ital,wght@0,600;0,700;1,600&display=swap');

/* --- Design Tokens --- */
:root {
  /* Colors */
  --primary: #3b82f6;
  --primary-hover: #2563eb;
  --secondary: #10b981;
  --accent: #8b5cf6;
  
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --bg-header: rgba(255, 255, 255, 0.8);
  
  --text-main: #0f172a;
  --text-muted: #475569;
  --text-light: #94a3b8;
  
  --border-color: #e2e8f0;
  --gradient-primary: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
  --gradient-secondary: linear-gradient(135deg, #10b981 0%, #3b82f6 100%);
  
  /* Typography */
  --font-sans: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: 'Playfair Display', Georgia, Cambria, "Times New Roman", Times, serif;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.02);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.07), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  
  /* Borders */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  
  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

ul {
  list-style: none;
}

section {
  padding: 100px 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  font-size: 2.25rem;
  font-weight: 800;
  margin-bottom: 12px;
  text-align: center;
  position: relative;
  letter-spacing: -0.025em;
}

.section-title span {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section-subtitle {
  font-size: 1rem;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 60px;
  font-weight: 400;
}

/* --- Layout Utility --- */
.container {
  width: 100%;
  margin-right: auto;
  margin-left: auto;
}

/* --- Header / Navigation --- */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: var(--bg-header);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  z-index: 1000;
  transition: all var(--transition-normal);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 80px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.03em;
}

.nav-menu {
  display: flex;
  gap: 32px;
}

.nav-link {
  font-weight: 500;
  color: var(--text-muted);
  position: relative;
  padding: 8px 0;
}

.nav-link:hover {
  color: var(--text-main);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width var(--transition-normal);
}

.nav-link:hover::after {
  width: 100%;
}

/* --- Hero Section --- */
.hero {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 48px;
  align-items: center;
  padding-top: 180px;
  padding-bottom: 120px;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  background-color: rgba(59, 130, 246, 0.1);
  color: var(--primary);
  border-radius: var(--radius-full);
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 24px;
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 24px;
  letter-spacing: -0.03em;
}

.hero-title span {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 600;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: 1.25rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  max-width: 540px;
}

.hero-cta {
  display: flex;
  gap: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  cursor: pointer;
}

.btn-primary {
  background: var(--gradient-primary);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
}

.btn-outline {
  border: 2px solid var(--border-color);
  color: var(--text-main);
  background-color: transparent;
}

.btn-outline:hover {
  border-color: var(--text-main);
  background-color: rgba(15, 23, 42, 0.03);
}

/* CSS Avatar Placeholder */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.avatar-placeholder {
  width: 320px;
  height: 320px;
  border-radius: var(--radius-full);
  background: var(--gradient-primary);
  padding: 8px;
  box-shadow: var(--shadow-xl);
  position: relative;
  animation: morph 8s ease-in-out infinite alternate;
}

.avatar-inner {
  width: 100%;
  height: 100%;
  background-color: var(--bg-card);
  border-radius: var(--radius-full);
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.avatar-inner span {
  font-size: 5rem;
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.avatar-inner::after {
  content: 'Photo Placeholder';
  position: absolute;
  bottom: 30px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-light);
}

@keyframes morph {
  0% {
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
  }
  50% {
    border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
  }
  100% {
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
  }
}

/* --- About Me Section --- */
.about-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 64px;
  align-items: center;
}

.about-info h3 {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 20px;
}

.about-text p {
  color: var(--text-muted);
  margin-bottom: 24px;
  font-size: 1.05rem;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 40px;
}

.stat-item {
  background-color: var(--bg-card);
  padding: 24px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  text-align: center;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.stat-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.stat-num {
  font-size: 2rem;
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: block;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 0.875rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Profile Details Card */
.about-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 40px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
}

.profile-table {
  width: 100%;
}

.profile-table tr {
  border-bottom: 1px solid var(--border-color);
}

.profile-table tr:last-child {
  border-bottom: none;
}

.profile-table td {
  padding: 16px 0;
}

.profile-table td.label {
  font-weight: 700;
  color: var(--text-main);
  width: 35%;
}

.profile-table td.value {
  color: var(--text-muted);
}

/* --- Skills Section --- */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
}

.skill-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
}

.skill-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
  border-color: rgba(59, 130, 246, 0.3);
}

.skill-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: var(--gradient-primary);
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 24px;
  color: #ffffff;
  font-size: 1.5rem;
}

.skill-card.sec .skill-icon {
  background: var(--gradient-secondary);
}

.skill-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.skill-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 24px;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-tag {
  background-color: var(--bg-main);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

/* --- Works Section --- */
.works-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 32px;
}

.work-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: all var(--transition-normal);
}

.work-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
}

/* CSS Work Thumbnail Placeholder */
.work-img-container {
  height: 220px;
  background-color: #f1f5f9;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  border-bottom: 1px solid var(--border-color);
  overflow: hidden;
}

.work-img-placeholder {
  width: 100%;
  height: 100%;
  background: var(--gradient-primary);
  opacity: 0.05;
  position: absolute;
  top: 0;
  left: 0;
}

.work-img-text {
  z-index: 2;
  text-align: center;
}

.work-img-text i {
  font-size: 2.5rem;
  color: var(--text-light);
  margin-bottom: 12px;
  display: block;
}

.work-img-text span {
  font-size: 0.875rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.work-card.alternate .work-img-container .work-img-placeholder {
  background: var(--gradient-secondary);
}

.work-content {
  padding: 32px;
}

.work-cat {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 12px;
  display: block;
}

.work-card.alternate .work-cat {
  color: var(--secondary);
}

.work-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.work-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 24px;
  height: 72px; /* Fix height for alignment */
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.work-link {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-main);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.work-link::after {
  content: '→';
  transition: transform var(--transition-fast);
}

.work-card:hover .work-link {
  color: var(--primary);
}

.work-card.alternate:hover .work-link {
  color: var(--secondary);
}

.work-card:hover .work-link::after {
  transform: translateX(4px);
}

/* --- Contact Section --- */
.contact-container {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 64px;
  background-color: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 60px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
}

.contact-info h3 {
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: 16px;
}

.contact-info p {
  color: var(--text-muted);
  margin-bottom: 32px;
}

.contact-methods {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 40px;
}

.contact-method-item {
  display: flex;
  align-items: center;
  gap: 16px;
}

.contact-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background-color: rgba(59, 130, 246, 0.05);
  color: var(--primary);
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.25rem;
}

.contact-method-item h4 {
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-light);
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}

.contact-method-item p {
  font-size: 1rem;
  color: var(--text-main);
  font-weight: 600;
  margin-bottom: 0;
}

.social-links {
  display: flex;
  gap: 16px;
}

.social-btn {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all var(--transition-fast);
}

.social-btn:hover {
  background-color: var(--text-main);
  color: #ffffff;
  border-color: var(--text-main);
  transform: translateY(-2px);
}

/* Contact Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-main);
}

.form-control {
  padding: 14px 18px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  font-family: var(--font-sans);
  font-size: 1rem;
  background-color: var(--bg-main);
  transition: all var(--transition-fast);
  color: var(--text-main);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  background-color: var(--bg-card);
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

/* --- Footer --- */
footer {
  border-top: 1px solid var(--border-color);
  background-color: var(--bg-card);
  padding: 40px 24px;
  text-align: center;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

/* --- Responsive Media Queries --- */
@media (max-width: 992px) {
  section {
    padding: 80px 24px;
  }
  
  .hero {
    grid-template-columns: 1fr;
    gap: 48px;
    padding-top: 140px;
    text-align: center;
  }
  
  .hero-content {
    align-items: center;
  }
  
  .hero-desc {
    margin-right: auto;
    margin-left: auto;
  }
  
  .about-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  
  .contact-container {
    grid-template-columns: 1fr;
    gap: 48px;
    padding: 40px;
  }
}

@media (max-width: 768px) {
  html {
    font-size: 15px;
  }
  
  .hero-title {
    font-size: 2.75rem;
  }
  
  .nav-menu {
    gap: 16px;
  }
  
  .about-stats {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .footer-container {
    flex-direction: column;
    gap: 20px;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2.25rem;
  }
  
  .hero-cta {
    flex-direction: column;
    width: 100%;
  }
  
  .btn {
    width: 100%;
  }
  
  .avatar-placeholder {
    width: 260px;
    height: 260px;
  }
}
