:root {
  --primary-color: #363663;
  --secondary-color: #633636;
  --gray: #4d4d4d;
  --light-gray: #f5f5f5;
  --text-gray: #666;
  --white: #ffffff;
  --max-width: 1200px;
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    sans-serif;
  line-height: 1.6;
  color: var(--gray);
  background-color: var(--white);
}

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

/* Header and Navigation */
header {
  background-color: var(--white);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

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

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

.logo-text {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--primary-color);
}

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

.nav-links a {
  text-decoration: none;
  color: var(--gray);
  font-weight: 500;
  transition: var(--transition);
}

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

/* Main content spacing */
main {
  margin-top: 80px;
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  color: var(--white);
  padding: 8rem 0;
  text-align: center;
  position: relative;
  overflow: hidden;
  min-height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  animation: drift 20s infinite linear;
}

@keyframes drift {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero-pattern {
  position: absolute;
  bottom: -50px;
  left: 0;
  right: 0;
  height: 150px;
  background: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 25px,
    rgba(255, 255, 255, 0.03) 25px,
    rgba(255, 255, 255, 0.03) 50px
  );
  pointer-events: none;
}

.hero-pattern-top {
  top: -50px;
  bottom: auto;
  transform: rotate(180deg);
}

.hero-pattern::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100%;
  background: linear-gradient(to top, var(--primary-color) 0%, transparent 100%);
  opacity: 0.5;
}

.hero h1 {
  font-size: 3.75rem;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.2;
  animation: fadeInUp 1s ease-out;
}

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

.tagline {
  font-size: 1.25rem;
  font-weight: 300;
  margin-bottom: 2rem;
  opacity: 0.9;
  animation: fadeInUp 1s ease-out 0.2s backwards;
}

.cta-button {
  display: inline-block;
  padding: 1rem 2rem;
  background-color: var(--white);
  color: var(--primary-color);
  text-decoration: none;
  border-radius: 5px;
  font-weight: 600;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  animation: fadeInUp 1s ease-out 0.4s backwards;
  position: relative;
  overflow: hidden;
}

.cta-button::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(54, 54, 99, 0.1);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition:
    width 0.6s,
    height 0.6s;
}

.cta-button:hover::before {
  width: 300px;
  height: 300px;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* Sections */
section {
  padding: 5rem 0;
  position: relative;
}

h2 {
  font-size: 2.5rem;
  color: var(--primary-color);
  text-align: center;
  margin-bottom: 3rem;
}

/* Section Dividers */
.section-divider {
  line-height: 0;
  margin: 0;
  overflow: hidden;
  background-color: var(--white);
}

.section-divider svg {
  position: relative;
  display: block;
  width: calc(100% + 1.3px);
  height: 60px;
}

.section-divider-reverse {
  background-color: var(--light-gray);
  transform: rotate(180deg);
}

/* Services */
.services {
  background-color: var(--light-gray);
  background-image: url("pattern.svg");
  background-size: 60px 60px;
  background-repeat: repeat;
  position: relative;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  position: relative;
  z-index: 1;
}

.service-card {
  background-color: var(--white);
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  transition: var(--transition);
  text-align: center;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
}

.service-icon {
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  opacity: 0.8;
  transition: var(--transition);
}

.service-card:hover .service-icon {
  transform: scale(1.1);
  opacity: 1;
}

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

.service-card h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.service-card p {
  color: var(--text-gray);
  line-height: 1.8;
}

/* About */
.about {
  text-align: center;
  position: relative;
}

.section-decoration {
  position: absolute;
  top: -50px;
  left: 50%;
  transform: translateX(-50%);
  z-index: -1;
  animation: float 6s ease-in-out infinite;
}

.decoration-logo {
  width: 300px;
  height: auto;
  opacity: 0.05;
}

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

.lead {
  font-size: 1.25rem;
  color: var(--primary-color);
  margin-bottom: 2rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.about p {
  max-width: 800px;
  margin: 0 auto;
  color: var(--text-gray);
  line-height: 1.8;
}

/* Contact */
.contact {
  background-color: var(--light-gray);
  text-align: center;
  background-image: linear-gradient(135deg, transparent 0%, rgba(54, 54, 99, 0.02) 50%, transparent 100%), url("pattern.svg");
  background-size:
    100% 100%,
    60px 60px;
  background-repeat: no-repeat, repeat;
}

/* Projects */
.projects {
  background-color: var(--white);
  text-align: center;
}

.section-subtitle {
  font-size: 1.25rem;
  color: var(--text-gray);
  margin-top: -1.5rem;
  margin-bottom: 3rem;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  max-width: 800px;
  margin: 0 auto;
  justify-content: center;
}

.project-card {
  background-color: var(--light-gray);
  padding: 3rem 2rem;
  border-radius: 8px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  transform: translateX(-100%);
  transition: transform 0.3s ease;
}

.project-card:hover::before {
  transform: translateX(0);
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.project-icon {
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  display: inline-block;
}

.project-card h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.project-card p {
  color: var(--text-gray);
  line-height: 1.8;
  margin-bottom: 1.5rem;
}

.project-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition);
}

.project-link:hover {
  color: var(--secondary-color);
  gap: 0.75rem;
}

.external-link-icon {
  width: 16px;
  height: 16px;
}

.project-placeholder {
  opacity: 0.6;
  border: 2px dashed rgba(54, 54, 99, 0.2);
  background-color: rgba(245, 245, 245, 0.5);
}

.project-placeholder .project-icon {
  opacity: 0.4;
}

.project-placeholder:hover {
  transform: none;
  box-shadow: none;
}

.contact p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  color: var(--text-gray);
}

.contact-methods {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
}

.contact-button {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 2rem;
  background-color: var(--primary-color);
  color: var(--white);
  text-decoration: none;
  border-radius: 5px;
  font-weight: 500;
  transition: var(--transition);
}

.contact-button:hover {
  background-color: var(--secondary-color);
  transform: translateY(-2px);
}

.contact-button svg {
  width: 20px;
  height: 20px;
}

.contact-button svg.email-icon {
  fill: none;
  stroke: currentColor;
}

/* Footer */
footer {
  background-color: var(--primary-color);
  color: var(--white);
  text-align: center;
  padding: 2rem 0;
}

footer p {
  opacity: 0.8;
}

/* Responsive Design */
@media (max-width: 768px) {
  .nav-links {
    gap: 1rem;
    font-size: 0.9rem;
  }

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

  .tagline {
    font-size: 1rem;
  }

  h2 {
    font-size: 2rem;
  }

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

  .service-icon {
    width: 40px;
    height: 40px;
  }

  .contact-methods {
    flex-direction: column;
    align-items: center;
  }

  .contact-button {
    width: 100%;
    max-width: 300px;
  }

  .projects-grid {
    grid-template-columns: 1fr;
    max-width: 400px;
  }
}

@media (max-width: 480px) {
  .logo img {
    height: 48px;
  }

  .logo-text {
    font-size: 1.2rem;
  }

  .nav-links {
    gap: 0.75rem;
    font-size: 0.85rem;
  }

  section {
    padding: 3rem 0;
  }

  .hero {
    padding: 5rem 0;
  }
}

/* Loading animation for smooth page transitions */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

section {
  animation: fadeIn 0.6s ease-out;
}
