/* ============================================
   PORTFOLIO STYLES
   ============================================ */

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

/* ============================================
   CSS VARIABLES & ROOT
   ============================================ */

:root {
  /* Colors - Light Mode */
  --background: #f7f5f0;
  --foreground: #241f1a;
  --card: #f2ede8;
  --card-foreground: #241f1a;
  --primary: #2d2622;
  --primary-foreground: #f7f5f0;
  --secondary: #e8e3dd;
  --secondary-foreground: #241f1a;
  --muted: #ebe5df;
  --muted-foreground: #756b5f;
  --accent: #d4a574;
  --accent-foreground: #241f1a;
  --border: #ddd5cc;
  --ring: #d4a574;

  /* Fonts */
  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', system-ui, sans-serif;

  /* Spacing */
  --radius: 6px;
}

body.dark {
  /* Colors - Dark Mode */
  --background: #1a1410;
  --foreground: #ebe5df;
  --card: #221c17;
  --card-foreground: #ebe5df;
  --primary: #ebe5df;
  --primary-foreground: #1a1410;
  --secondary: #2d2622;
  --secondary-foreground: #ebe5df;
  --muted: #2d2622;
  --muted-foreground: #9e9490;
  --accent: #d4a574;
  --accent-foreground: #1a1410;
  --border: #3a3530;
  --ring: #d4a574;
}

/* ============================================
   GLOBAL STYLES
   ============================================ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  border-color: var(--border);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--background);
  color: var(--foreground);
  transition: background-color 0.3s ease, color 0.3s ease;
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
}

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */

.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background-color: var(--background);
  border-bottom: 1px solid var(--border);
  animation: slideDown 0.5s ease;
}

@keyframes slideDown {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(0);
  }
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
}

.logo {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
  letter-spacing: -0.5px;
  transition: color 0.3s ease;
}

.logo:hover {
  color: var(--accent);
}

.logo .accent {
  color: var(--accent);
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.theme-toggle,
.menu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: var(--muted-foreground);
  transition: color 0.3s ease, background-color 0.3s ease;
}

.theme-toggle:hover,
.menu-toggle:hover {
  color: var(--foreground);
  background-color: var(--secondary);
}

.sun-icon {
  display: block;
}

.moon-icon {
  display: none;
}

body.dark .sun-icon {
  display: none;
}

body.dark .moon-icon {
  display: block;
}

.menu-toggle {
  display: none;
}

.mobile-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 1.5rem;
  width: 200px;
  background-color: rgba(247, 245, 240, 0.95);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  flex-direction: column;
  padding: 0.5rem 0;
  margin-top: 0.5rem;
  animation: slideDown 0.3s ease;
}

body.dark .mobile-menu {
  background-color: rgba(26, 20, 16, 0.95);
}

.mobile-menu button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0.625rem 1rem;
  font-size: 0.875rem;
  font-family: var(--font-body);
  font-weight: 500;
  color: var(--muted-foreground);
  transition: color 0.3s ease, background-color 0.3s ease;
}

.mobile-menu button:hover {
  color: var(--foreground);
  background-color: var(--secondary);
}

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

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 1.5rem 2.5rem;
  position: relative;
  margin-top: 60px;
}

.hero-content {
  max-width: 48rem;
  text-align: center;
  animation: fadeInUp 0.7s ease;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.profile-image-container {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.profile-image {
  width: 128px;
  height: 128px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--accent);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.hero-subtitle {
  font-size: 0.875rem;
  font-family: var(--font-body);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--foreground);
  margin-bottom: 2rem;
}

.hero-tagline {
  font-size: 1.125rem;
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.6;
  color: var(--muted-foreground);
  max-width: 42rem;
  margin: 0 auto 2.5rem;
}

.hero-buttons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  padding: 0.75rem 2rem;
  font-size: 0.875rem;
  font-family: var(--font-body);
  font-weight: 500;
  border-radius: var(--radius);
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--primary-foreground);
}

.btn-primary:hover {
  opacity: 0.9;
}

.btn-secondary {
  border: 1px solid var(--border);
  color: var(--foreground);
  background-color: transparent;
}

.btn-secondary:hover {
  background-color: var(--secondary);
}

.btn-accent {
  border: 1px solid var(--accent);
  color: var(--accent);
}

.btn-accent:hover {
  background-color: var(--accent);
  color: var(--accent-foreground);
}

.btn-large {
  padding: 0.875rem 2.5rem;
}

.scroll-indicator {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  color: var(--muted-foreground);
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(10px);
  }
}

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

.section {
  padding: 5rem 1.5rem;
}

.section-container {
  max-width: 56rem;
  margin: 0 auto;
}

.accent-line {
  width: 3rem;
  height: 2px;
  background-color: var(--accent);
  margin-bottom: 1.5rem;
}

.section-title {
  font-size: 2.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--foreground);
  margin-bottom: 3rem;
}

.about-section {
  background-color: var(--card);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
}

.about-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.about-paragraph {
  font-size: 1rem;
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.8;
  color: var(--muted-foreground);
}

.about-info {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.info-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--muted-foreground);
}

.info-item svg {
  color: var(--accent);
  flex-shrink: 0;
}

.info-item span {
  font-size: 0.875rem;
  font-family: var(--font-body);
}

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

.skills-section {
  background-color: var(--background);
}

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

.skill-category {
  display: flex;
  flex-direction: column;
}

.skill-category-title {
  font-family: var(--font-heading);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 1rem;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.skill-tag {
  padding: 0.375rem 0.75rem;
  font-size: 0.75rem;
  font-family: var(--font-body);
  font-weight: 500;
  background-color: var(--secondary);
  color: var(--secondary-foreground);
  border-radius: var(--radius);
}

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

.projects-section {
  background-color: var(--card);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.project-card {
  padding: 1.5rem;
  background-color: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all 0.3s ease;
  animation: fadeInUp 0.5s ease;
}

.project-card:hover {
  border-color: rgba(212, 165, 116, 0.4);
}

.project-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 0.75rem;
}

.project-description {
  font-size: 0.875rem;
  font-family: var(--font-body);
  color: var(--muted-foreground);
  margin-bottom: 1rem;
  line-height: 1.6;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin-bottom: 1.25rem;
}

.tech-tag {
  padding: 0.25rem 0.5rem;
  font-size: 0.75rem;
  font-family: var(--font-body);
  background-color: var(--secondary);
  color: var(--muted-foreground);
  border-radius: var(--radius);
}

.project-links {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.project-links a {
  color: var(--accent);
  transition: color 0.3s ease;
}

.project-links a:hover {
  color: var(--foreground);
}

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

.experience-section {
  background-color: var(--background);
}

.experience-list {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.experience-item {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.experience-item:last-child {
  border-bottom: none;
}

.experience-period {
  font-size: 0.875rem;
  font-family: var(--font-body);
  color: var(--muted-foreground);
}

.experience-content {
  display: flex;
  flex-direction: column;
}

.experience-role {
  font-family: var(--font-heading);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--foreground);
}

.experience-company {
  font-size: 0.875rem;
  font-family: var(--font-body);
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.experience-description {
  font-size: 0.875rem;
  font-family: var(--font-body);
  color: var(--muted-foreground);
  line-height: 1.6;
}

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

.contact-section {
  background-color: var(--card);
}

.contact-container {
  text-align: center;
}

.contact-description {
  font-size: 1.125rem;
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.6;
  color: var(--muted-foreground);
  max-width: 32rem;
  margin: 0 auto 2.5rem;
}

.social-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 3rem;
}

.social-links a {
  color: var(--muted-foreground);
  transition: color 0.3s ease;
}

.social-links a:hover {
  color: var(--foreground);
}

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

.footer {
  padding: 2rem 1.5rem;
  border-top: 1px solid var(--border);
}

.footer-container {
  max-width: 56rem;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.footer-text {
  font-size: 0.75rem;
  font-family: var(--font-body);
  color: var(--muted-foreground);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 768px) {
  .hero {
    padding: 5rem 1.5rem 2rem;
  }

  .hero-title {
    font-size: 2.5rem;
  }

  .hero-tagline {
    font-size: 1rem;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    justify-content: center;
  }

  .section {
    padding: 3.5rem 1.5rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .skills-grid {
    grid-template-columns: 1fr;
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }

  .experience-item {
    grid-template-columns: 100px 1fr;
    gap: 1.5rem;
  }

  .experience-period {
    font-size: 0.8rem;
  }

  .menu-toggle {
    display: flex;
  }

  .mobile-menu.active {
    display: flex;
  }

  .footer-container {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 0.75rem;
  }

  .section-title {
    font-size: 1.75rem;
  }

  .btn {
    padding: 0.625rem 1.5rem;
    font-size: 0.8125rem;
  }

  .experience-item {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .experience-period {
    margin-bottom: 0.5rem;
  }

  .social-links {
    gap: 1rem;
  }

  .social-links svg {
    width: 18px;
    height: 18px;
  }
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Smooth transitions for theme switching */
* {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

button, a {
  transition: all 0.3s ease;
}
