@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700');
@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');


:root {
  --google-blue: #1a73e8;
  /* slightly darker blue for better contrast/accessibility */
  --google-blue-light: #e8f0fe;
  --google-red: #ea4335;
  --google-yellow: #fbbc04;
  --google-green: #34a853;
  --google-green-light: #e6f4ea;

  /* Whole application unified background color */
  --bg-primary: #ffffff;
  --bg-secondary: #ffffff;
  --bg-tertiary: #f1f3f4;

  /* Buttons: light mode equivalent */
  --btn-bg: #f8f9fa;
  --btn-border: #f8f9fa;
  --btn-hover-bg: #f1f3f4;
  --btn-hover-border: #dadce0;

  --text-primary: #202124;
  --text-secondary: #5f6368;
  --text-tertiary: #70757a;

  --border-color: #dadce0;
  --border-focus: #1a73e8;

  --shadow-1: 0 1px 2px 0 rgba(60, 64, 67, 0.3), 0 1px 3px 1px rgba(60, 64, 67, 0.15);
  --shadow-2: 0 1px 2px 0 rgba(60, 64, 67, 0.3), 0 2px 6px 2px rgba(60, 64, 67, 0.15);
  --shadow-3: 0 1px 3px 0 rgba(60, 64, 67, 0.3), 0 4px 8px 3px rgba(60, 64, 67, 0.15);

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 9999px;

  --gutter: 1.5rem;
  --section-padding: 5rem;
  --container-max: 1100px;

  --chip-hover-bg: #e8eaed;
}

[data-theme="dark"] {
  /* Whole application unified background color: #202124 */
  --bg-primary: #202124;
  --bg-secondary: #202124;
  --bg-tertiary: #303134;

  /* Buttons: dark mode color #303134 */
  --btn-bg: #303134;
  --btn-border: #303134;
  --btn-hover-bg: #3c4043;
  --btn-hover-border: #5f6368;

  --text-primary: #ffffff;
  --text-secondary: #c0c6cc;
  --text-tertiary: #c0c6cc;
  --border-color: #3c4043;
  --shadow-1: 0 1px 2px 0 rgba(0, 0, 0, 0.3), 0 1px 3px 1px rgba(0, 0, 0, 0.15);
  --shadow-2: 0 1px 2px 0 rgba(0, 0, 0, 0.3), 0 2px 6px 2px rgba(0, 0, 0, 0.15);
  --shadow-3: 0 1px 3px 0 rgba(0, 0, 0, 0.3), 0 4px 8px 3px rgba(0, 0, 0, 0.15);
  --chip-hover-bg: #3c4043;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  font-family: 'Montserrat', sans-serif;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  margin: 0;
  overflow-x: hidden;
  line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Outfit', sans-serif;
  font-weight: 500;
  margin: 0;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

/* Typography */
.font-display {
  font-size: 3rem;
  line-height: 1.2;
  font-weight: 400;
}

@media (min-width: 768px) {
  .font-display {
    font-size: 4.5rem;
  }
}

.font-headline-lg {
  font-size: 2.25rem;
  font-weight: 400;
}

.font-headline-md {
  font-size: 1.5rem;
}

.font-body-lg {
  font-size: 1.125rem;
}

.font-body-md {
  font-size: 1rem;
}

.font-label-md {
  font-family: 'Outfit', sans-serif;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.25px;
}

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

.text-secondary {
  color: var(--text-secondary);
}

.text-blue {
  color: var(--google-blue);
}

.text-red {
  color: var(--google-red);
}

.text-yellow {
  color: var(--google-yellow);
}

.text-green {
  color: var(--google-green);
}

/* Material Symbols */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  display: inline-block;
  vertical-align: middle;
}

.material-symbols-outlined.filled {
  font-variation-settings: 'FILL' 1;
}

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

p {
  margin: 0;
}

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section {
  padding: var(--section-padding) 0;
}

.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 50;
  background-color: var(--bg-primary);
  border-bottom: 1px solid transparent;
  transition: all 0.2s ease;
}

.navbar.scrolled {
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-1);
}

.navbar-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 64px;
  /* Standard Google app bar height */
}

.navbar-brand {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.navbar-brand .logo-g {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--google-blue);
}

.navbar-links {
  display: none;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .navbar-links {
    display: flex;
    align-items: center;
  }
}

.navbar-links a {
  color: var(--text-secondary);
  transition: color 0.2s;
}

.navbar-links a:hover {
  color: var(--text-primary);
}

.btn-primary {
  padding: 0 1.5rem;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: var(--google-blue);
  color: white;
  border-radius: 4px;
  transition: background-color 0.2s, box-shadow 0.2s;
  box-shadow: 0 1px 2px 0 rgba(60, 64, 67, 0.3), 0 1px 3px 1px rgba(60, 64, 67, 0.15);
}

.btn-primary:hover {
  background-color: #1b66c9;
  box-shadow: 0 1px 3px 0 rgba(60, 64, 67, 0.3), 0 4px 8px 3px rgba(60, 64, 67, 0.15);
}

/* Hero Section - Search Style */
.hero {
  min-height: 62vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: 64px;
  /* Offset navbar */
}

.hero-logo {
  font-family: 'Outfit', sans-serif;
  font-size: 4rem;
  font-weight: 500;
  letter-spacing: -2px;
  margin-bottom: 2rem;
  color: var(--text-primary);
}

@media (min-width: 768px) {
  .hero-logo {
    font-size: 5.5rem;
  }
}

.search-bar-container {
  width: 100%;
  max-width: 600px;
  margin: 0 auto 2rem auto;
  position: relative;
  z-index: 50;
}

.search-bar {
  display: flex;
  align-items: center;
  width: 100%;
  height: 48px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-pill);
  padding: 0 1rem;
  box-shadow: none;
  transition: box-shadow 0.2s, border-color 0.2s, border-radius 0.15s;
  position: relative;
}


/* When suggestions dropdown is open */
.search-bar-container.has-suggestions .search-bar {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  border-bottom-color: transparent;
  box-shadow: 0 4px 12px rgba(32, 33, 36, .22);
}

.search-icon {
  color: var(--text-tertiary);
  margin-right: 0.5rem;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.search-input {
  flex-grow: 1;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text-primary);
  outline: none;
  padding: 0 0.5rem;
  height: 100%;
  min-width: 0;
}

.search-input::placeholder {
  opacity: 0.85;
}

.search-clear-btn {
  background: none;
  border: none;
  color: var(--text-tertiary);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  margin-right: 0.25rem;
  transition: color 0.15s, background-color 0.15s;
}

.search-clear-btn:hover {
  color: var(--text-primary);
  background: var(--bg-tertiary);
}

.search-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-primary);
  border: 1px solid transparent;
  border-top: 1px solid var(--border-color);
  border-bottom-left-radius: 24px;
  border-bottom-right-radius: 24px;
  box-shadow: 0 6px 16px rgba(32, 33, 36, .25);
  margin: 0;
  padding: 0.5rem 0 0.75rem 0;
  list-style: none;
  overflow: hidden;
  z-index: 100;
  animation: fadeInDown 0.15s ease-out;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.suggestion-item {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 0.625rem 1.25rem;
  cursor: pointer;
  text-align: left;
  font-size: 0.9375rem;
  color: var(--text-primary);
  transition: background-color 0.15s;
}

.suggestion-item:hover,
.suggestion-item.selected {
  background: var(--btn-bg);
}

.suggestion-icon {
  color: var(--text-tertiary);
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.suggestion-text {
  flex-grow: 1;
}

.suggestion-text strong {
  font-weight: 600;
  color: var(--google-blue);
}

.suggestion-badge {
  font-size: 0.75rem;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  font-weight: 500;
}

.search-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-left: 0.5rem;
}

.search-action-btn {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: transform 0.15s ease, opacity 0.15s ease;
  color: inherit;
}

.search-action-btn:hover {
  transform: scale(1.12);
}

.search-action-btn svg {
  display: block;
}

.hero-buttons {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  margin-bottom: 2rem;
}

.btn-secondary {
  padding: 0 1.25rem;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: var(--btn-bg);
  color: var(--text-primary);
  border: 1px solid var(--btn-border);
  border-radius: 4px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.875rem;
  transition: all 0.2s;
  cursor: pointer;
  text-decoration: none;
}

.btn-secondary:hover {
  background-color: var(--btn-hover-bg);
  border-color: var(--btn-hover-border);
  color: var(--text-primary);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .15);
}

.hero-subtitle {
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

/* Projects Section (Google Play / App style) */
.section-header {
  margin-bottom: 2rem;
}

.section-title {
  font-size: 1.75rem;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.section-subtitle {
  color: var(--text-secondary);
}

.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .projects-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1024px) {
  .projects-grid {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

.project-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: box-shadow 0.2s, transform 0.2s;
  cursor: pointer;
  height: 100%;
}

.project-card:hover {
  box-shadow: var(--shadow-2);
}

.project-image-wrapper {
  position: relative;
  height: 180px;
  min-height: 180px;
  max-height: 180px;
  flex: 0 0 180px;
  width: 100%;
  background: var(--bg-secondary);
  overflow: hidden;
  box-sizing: border-box;
}

.project-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.project-image-wrapper.npm-bg {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--google-red), #b9322b);
}

.project-image-wrapper .npm-icon {
  font-size: 64px;
  color: white;
}

/* Re-go App Mockup */
.project-image-wrapper.rego-bg {
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, #1b5e20 0%, #0d381e 70%, #061e0e 100%);
  padding: 12px;
  box-sizing: border-box;
}

.project-image-wrapper.rego-bg .rego-phone-img {
  width: auto !important;
  height: 100% !important;
  max-height: 156px;
  max-width: 90%;
  object-fit: contain !important;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  transition: transform 0.25s ease;
}

.project-card:hover .project-image-wrapper.rego-bg .rego-phone-img {
  transform: translateY(-2px) scale(1.03);
}

/* Parchados Logo Box */
.project-image-wrapper.parchados-bg {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0A0A0A;
  box-sizing: border-box;
}

.project-image-wrapper.parchados-bg .parchados-logo-img {
  height: 60px !important;
  width: auto !important;
  max-width: 80%;
  object-fit: contain !important;
  transition: transform 0.25s ease;
}

.project-card:hover .project-image-wrapper.parchados-bg .parchados-logo-img {
  transform: scale(1.04);
}

.project-content {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.project-title {
  font-size: 1.125rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
  color: var(--text-primary);
}

.project-desc {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
  flex-grow: 1;
}

.project-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--google-blue);
  margin-top: auto;
}


.project-link:hover {
  text-decoration: underline;
}

.project-link .material-symbols-outlined {
  font-size: 18px;
}

/* Skills Section (Material Chips) */
.skills-section {
  background: var(--bg-secondary);
}

.skills-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 800px;
  margin: 0 auto;
}

.skill-category {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.5rem;
}

.skill-category-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.skill-category-icon {
  color: var(--google-blue);
}

.skill-category-title {
  font-size: 1.125rem;
}

.skill-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.skill-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  height: 36px;
  padding: 0 14px 0 10px;
  background: var(--btn-bg);
  color: var(--text-primary);
  border-radius: var(--radius-pill);
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid var(--border-color);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.15s ease, box-shadow 0.15s ease;
  cursor: default;
  user-select: none;
}

.skill-chip:hover {
  background: var(--btn-hover-bg);
  color: var(--text-primary);
  border-color: var(--google-blue);
  transform: translateY(-2px);
  box-shadow: var(--shadow-1);
}

.skill-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
  display: inline-block;
  vertical-align: middle;
}

/* Ensure contrast for Next.js dark logo in dark theme */
[data-theme="dark"] .skill-icon-nextjs {
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.1);
}

/* Experience Section (Google Timeline) */
.timeline {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
}

.timeline-item {
  position: relative;
  padding-left: 60px;
  margin-bottom: 2.5rem;
}

.timeline-item:not(:last-child)::before {
  content: '';
  position: absolute;
  top: 21px;
  bottom: calc(-2.5rem - 21px);
  left: 20px;
  width: 2px;
  background: var(--border-color);
  z-index: 1;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-icon {
  position: absolute;
  left: 0;
  top: 0;
  width: 42px;
  height: 42px;
  background: var(--bg-primary);
  border: 2px solid var(--google-blue);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--google-blue);
  z-index: 2;
}

.timeline-item:nth-child(2) .timeline-icon {
  border-color: var(--google-red);
  color: var(--google-red);
}

.timeline-item:nth-child(3) .timeline-icon {
  border-color: var(--google-yellow);
  color: var(--google-yellow);
}

.timeline-item:nth-child(4) .timeline-icon {
  border-color: var(--google-green);
  color: var(--google-green);
}

.timeline-content {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
  position: relative;
  transition: box-shadow 0.2s;
}

.timeline-content:hover {
  box-shadow: var(--shadow-1);
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}

.timeline-role {
  font-size: 1.125rem;
  color: var(--text-primary);
  font-weight: 500;
}

.timeline-company {
  color: var(--text-secondary);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

.timeline-date {
  color: var(--text-tertiary);
  font-size: 0.875rem;
}

.timeline-desc {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-top: 0.75rem;
  margin-bottom: 1rem;
}

/* Contact / Footer Section */
.footer-section {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 4rem 0 2rem 0;
  text-align: center;
}

.contact-card {
  max-width: 600px;
  margin: 0 auto 3rem auto;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2.5rem;
  box-shadow: var(--shadow-1);
}

.contact-card h2 {
  margin-bottom: 1rem;
}

.contact-card p {
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.contact-link {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.625rem 1.25rem;
  background: var(--btn-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-pill);
  color: var(--text-primary);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.15s ease, box-shadow 0.15s ease;
}

.contact-link:hover {
  background: var(--btn-hover-bg);
  color: var(--google-blue);
  border-color: var(--google-blue);
  transform: translateY(-2px);
  box-shadow: var(--shadow-1);
}

.contact-icon {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 4px;
  display: inline-block;
  vertical-align: middle;
}

[data-theme="dark"] .contact-icon-github {
  filter: invert(1) brightness(1.2);
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  color: var(--text-tertiary);
  font-size: 0.875rem;
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
  }
}

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

.footer-links a:hover {
  color: var(--text-secondary);
  text-decoration: underline;
}

/* SEO & Accessibility Screen Reader Only Utility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}