/* ===== Fonts ===== */
@font-face {
  font-family: 'Quantify';
  src: url('/css/Quantify.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* ===== Custom Properties ===== */
:root {
  --color-primary: #38b137;
  --color-primary-dark: #2d8f2c;
  --color-primary-light: #e8f5e8;
  --color-blue: #3780ff;
  --color-yellow: #fcbd05;
  --color-text: #303030;
  --color-text-light: #555;
  --color-bg: #ffffff;
  --color-bg-alt: #f5f5f5;
  --color-border: #e2e8f0;
  --font-body: 'DM Sans', system-ui, -apple-system, sans-serif;
  --font-heading: 'Poppins', system-ui, -apple-system, sans-serif;
  --font-logo: 'Quantify', sans-serif;
  --max-width: 1100px;
  --radius: 8px;
}

/* ===== Dark Mode ===== */
@media (prefers-color-scheme: dark) {
  :root {
    --color-primary: #38b137;
    --color-primary-dark: #2d8f2c;
    --color-primary-light: #1a3a1a;
    --color-blue: #5a9bff;
    --color-text: #e8e8e8;
    --color-text-light: #aaa;
    --color-bg: #1a1a1a;
    --color-bg-alt: #242424;
    --color-border: #333;
  }
}

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

html {
  scroll-behavior: smooth;
}

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

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

a {
  color: var(--color-primary);
  text-decoration: none;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
}

/* ===== Layout ===== */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ===== Header ===== */
.site-header {
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 88px;
}

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

.logo img {
  height: 80px;
  width: auto;
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
  align-items: center;
}

.nav-links a {
  color: var(--color-text);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--color-primary);
}

.nav-links .btn-nav {
  background: var(--color-primary);
  color: #fff;
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius);
  font-weight: 500;
  transition: background 0.2s;
}

.nav-links .btn-nav:hover,
.nav-links .btn-nav.active {
  background: var(--color-primary-dark);
  color: #fff;
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  margin: 6px 0;
  transition: all 0.3s;
}

.nav-toggle.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 6px);
}

.nav-toggle.open span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -6px);
}

/* ===== Hero ===== */
.hero {
  padding: 5rem 0 4rem;
  text-align: center;
  background: var(--color-bg-alt);
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: 1.25rem;
  color: var(--color-text);
}

.hero h1 em {
  font-style: normal;
  color: var(--color-blue);
}

.hero p {
  font-size: 1.15rem;
  color: var(--color-text-light);
  max-width: 640px;
  margin: 0 auto 2rem;
}

.btn-primary {
  display: inline-block;
  background: var(--color-primary);
  color: #fff;
  padding: 0.75rem 2rem;
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  transition: background 0.2s, transform 0.2s;
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  background: var(--color-primary-dark);
  color: #fff;
  transform: translateY(-1px);
}

/* ===== Services Grid ===== */
.services {
  padding: 5rem 0;
}

.services h2 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.services .subtitle {
  text-align: center;
  color: var(--color-text-light);
  margin-bottom: 3rem;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.service-card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 2rem;
  transition: box-shadow 0.2s, transform 0.2s;
}

.service-card:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.service-card .icon {
  width: 48px;
  height: 48px;
  background: var(--color-primary-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  color: var(--color-primary);
}

.service-card .icon svg {
  width: 24px;
  height: 24px;
}

.service-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
}

.service-card h3 a {
  color: inherit;
  text-decoration: none;
}

.service-card h3 a:hover {
  color: var(--color-primary);
}

.service-card p {
  color: var(--color-text-light);
  font-size: 0.95rem;
}

/* ===== About Page ===== */
.page-header {
  padding: 3.5rem 0;
  background: var(--color-bg-alt);
  text-align: center;
}

.page-header h1 {
  font-size: 2.25rem;
  margin-bottom: 0.75rem;
}

.page-header p {
  color: var(--color-text-light);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

.about-content {
  padding: 4rem 0;
}

.about-hero {
  display: flex;
  align-items: center;
  gap: 3rem;
  max-width: 800px;
  margin: 0 auto 3rem;
}

.about-hero-photo {
  flex-shrink: 0;
  text-align: center;
}

.about-hero img {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--color-primary-light);
}

.about-hero-name {
  margin-top: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--color-text);
}

.about-hero-text {
  font-size: 1.05rem;
  color: var(--color-text-light);
  line-height: 1.7;
}

.linkedin-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #0a66c2;
  font-weight: 500;
  font-size: 0.95rem;
  transition: opacity 0.2s;
}

.linkedin-link:hover {
  opacity: 0.75;
}

.services-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-bottom: 3rem;
}

.services-list-item {
  background: var(--color-bg-alt);
  border-radius: var(--radius);
  padding: 2rem;
}

.services-list-item h3 {
  font-size: 1.15rem;
  margin-bottom: 1rem;
  color: var(--color-primary);
}

.services-list-item ul {
  list-style: none;
  padding: 0;
}

.services-list-item li {
  padding: 0.35rem 0;
  color: var(--color-text-light);
  font-size: 0.95rem;
  padding-left: 1.25rem;
  position: relative;
}

.services-list-item li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.7rem;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-primary);
}

/* ===== Contact Page ===== */
.contact-content {
  padding: 4rem 0;
}

.contact-layout {
  max-width: 640px;
  margin: 0 auto;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

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

.form-group label {
  font-weight: 500;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  color: var(--color-text);
}

.form-group input,
.form-group textarea {
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-bg-alt);
  color: var(--color-text);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(56, 177, 55, 0.15);
}

.form-group textarea {
  resize: vertical;
  min-height: 140px;
}

.form-status {
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  display: none;
}

.form-status.success {
  display: block;
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.form-status.error {
  display: block;
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* ===== CTA Section ===== */
.cta {
  padding: 4rem 0;
  background: var(--color-primary);
  text-align: center;
  color: #fff;
}

.cta h2 {
  font-size: 1.75rem;
  margin-bottom: 0.75rem;
}

.cta p {
  opacity: 0.9;
  margin-bottom: 1.5rem;
}

.btn-white {
  display: inline-block;
  background: #fff;
  color: var(--color-primary);
  padding: 0.75rem 2rem;
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-white:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  color: var(--color-primary);
}

/* ===== Footer ===== */
.site-footer {
  padding: 2rem 0;
  border-top: 1px solid var(--color-border);
  text-align: center;
  color: var(--color-text-light);
  font-size: 0.875rem;
}

.footer-links {
  margin-top: 0.5rem;
}

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

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

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 88px;
    left: 0;
    right: 0;
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    flex-direction: column;
    padding: 1rem 1.5rem;
    gap: 0.75rem;
  }

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

  .hero h1 {
    font-size: 1.75rem;
  }

  .hero {
    padding: 3rem 0 2.5rem;
  }

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

  .services-list {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .about-hero {
    flex-direction: column;
    text-align: center;
    gap: 1.5rem;
  }

  .about-hero img {
    width: 140px;
    height: 140px;
  }
}

/* ===== Dark Mode Overrides ===== */
@media (prefers-color-scheme: dark) {
  .logo img {
    filter: brightness(0) invert(1);
  }

  .service-card:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  }

  .form-status.success {
    background: #0d2818;
    color: #4ade80;
    border-color: #166534;
  }

  .form-status.error {
    background: #2d1215;
    color: #f87171;
    border-color: #991b1b;
  }

  .linkedin-link {
    color: #3b9eff;
  }

  .btn-white:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  }
}
