/* --- Reset & base --- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: #1e293b;
  background: #f8fafc;
}
img { max-width: 100%; height: auto; display: block; }
a { color: #0d9488; text-decoration: none; }
a:hover { text-decoration: underline; }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* --- Header --- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 250, 252, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #e2e8f0;
}
.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.875rem;
  padding-bottom: 0.875rem;
}
.logo {
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-size: 1.25rem;
  color: #0f172a;
  text-decoration: none;
}
.logo:hover { text-decoration: none; }
.nav { display: flex; gap: 1.5rem; }
.nav a {
  color: #475569;
  font-weight: 500;
  font-size: 0.9375rem;
}
.nav a:hover { color: #0d9488; }

/* --- Hero --- */
.hero {
  padding: 4rem 0 5rem;
  text-align: center;
}
.hero-label {
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #0d9488;
  margin: 0 0 0.5rem;
}
.hero-title {
  font-family: 'Fraunces', serif;
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 1rem;
  line-height: 1.15;
}
.hero-desc {
  max-width: 520px;
  margin: 0 auto;
  font-size: 1.125rem;
  color: #475569;
}

/* --- Work --- */
.work { padding: 3rem 0 4rem; }
.section-title {
  font-family: 'Fraunces', serif;
  font-size: 1.75rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 2rem;
}
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
}
.project-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.project-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}
.project-card--featured {
  border-color: #99f6e4;
  background: linear-gradient(to bottom, #f0fdfa, #fff);
}
.project-meta {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  margin-bottom: 0.5rem;
}
.project-name {
  font-family: 'Fraunces', serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem;
}
.project-desc {
  font-size: 0.9375rem;
  color: #475569;
  margin: 0 0 1rem;
  line-height: 1.5;
}
.project-link {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #0d9488;
}
.project-link:hover { text-decoration: none; opacity: 0.85; }

/* --- ERP --- */
.erp {
  padding: 3rem 0 4rem;
  background: #fff;
  border-top: 1px solid #e2e8f0;
}
.erp-intro {
  font-size: 1.0625rem;
  color: #475569;
  margin: 0 0 1.5rem;
  max-width: 640px;
}
.erp-features {
  margin: 0 0 2.5rem;
  padding-left: 1.25rem;
  color: #475569;
  font-size: 0.9375rem;
  line-height: 1.7;
}
.erp-features li { margin-bottom: 0.35rem; }
.erp-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}
.gallery-item {
  margin: 0;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}
.gallery-trigger {
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  text-align: left;
}
.gallery-trigger:hover { opacity: 0.92; }
.gallery-trigger img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}
.gallery-item figcaption {
  padding: 0.625rem 1rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #475569;
}

/* --- Contact --- */
.contact {
  padding: 4rem 0 5rem;
  text-align: center;
}
.contact-desc {
  max-width: 480px;
  margin: 0 auto 1.5rem;
  font-size: 1.0625rem;
  color: #475569;
}
.contact-actions {
  margin-bottom: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.15s;
  text-decoration: none;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary {
  background: #0d9488;
  color: #fff;
}
.btn-primary:hover { opacity: 0.9; }
.btn-whatsapp {
  background: #25d366;
  color: #fff;
}
.btn-whatsapp:hover { opacity: 0.9; }

/* --- Footer --- */
.footer {
  padding: 1.5rem 0;
  border-top: 1px solid #e2e8f0;
  text-align: center;
}
.footer p {
  margin: 0;
  font-size: 0.875rem;
  color: #64748b;
}

/* --- Lightbox --- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(15, 23, 42, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
}
.lightbox.is-open {
  opacity: 1;
  visibility: visible;
}
.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 44px;
  height: 44px;
  font-size: 1.75rem;
  line-height: 1;
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s;
}
.lightbox-close:hover { background: rgba(255, 255, 255, 0.2); }
.lightbox-inner {
  max-width: 95vw;
  max-height: 90vh;
  overflow: auto;
}
.lightbox-inner img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

/* --- Responsive --- */
@media (max-width: 640px) {
  .nav { gap: 1rem; }
  .nav a { font-size: 0.875rem; }
  .hero { padding: 3rem 0 4rem; }
  .work { padding: 2rem 0 3rem; }
  .erp { padding: 2rem 0 3rem; }
  .erp-gallery { grid-template-columns: 1fr; }
  .contact { padding: 3rem 0 4rem; }
}
