/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-color: #06182a; /* Dark Blue from Rovanth logo text */
  --accent-color: #2b70f0; /* A vibrant blue from the gear/arrow in the logo */
  --accent-secondary: #0c8227; /* A vibrant green from the circuit line in the logo */
  --text-dark: #212529; /* Kept for general dark text contrast */
  --text-light: #6c757d; /* Kept for secondary text contrast */
  --background-light: #f4f7f8; /* A very light gray-blue for backgrounds */
  --white: #ffffff;
  --border-light: #e9ecef;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
  --border-radius: 8px;
  --transition: all 0.3s ease;
}

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

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 1rem;
  /* color: var(--primary-color); */
}

h1 {
  font-size: 3rem;
}
h2 {
  font-size: 2.5rem;
}
h3 {
  font-size: 1.5rem;
}
h4 {
  font-size: 1.25rem;
}

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

.section-title {
  text-align: center;
  margin-bottom: 3rem;
  font-size: 2.5rem;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.875rem 2rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: var(--border-radius);
  transition: var(--transition);
  border: none;
  cursor: pointer;
  font-size: 1rem;
  text-align: center;
}

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

.btn-primary:hover {
  background: #1c52bd;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline {
  background: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.btn-outline:hover {
  background: var(--primary-color);
  color: var(--white);
}

/* Header */
.header {
  background: var(--white);
  box-shadow: var(--shadow);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
}

.navbar {
  padding: 1rem 0;
}

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

.logo {
  height: 50px;
  width: auto;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
  margin: 0;
}

.nav-link {
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 500;
  transition: var(--transition);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--accent-color);
}

.nav-link.active::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent-color);
}

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 4px;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: var(--text-dark);
  transition: var(--transition);
}

/* Hero Section */
.hero {
  background: linear-gradient(
    135deg,
    var(--background-light) 0%,
    var(--white) 100%
  );
  padding: 150px 0 80px;
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  color: var(--primary-color);
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-light);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.hero-services {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2.5rem;
}

.service-tag {
  background: #e1e9f2;
  color: var(--text-dark);
  padding: 0.5rem 1rem;
  border-radius: 25px;
  font-size: 0.875rem;
  font-weight: 500;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

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

.floating-card {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  text-align: center;
  transition: var(--transition);
}

.floating-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.floating-card:nth-child(2) {
  margin-top: 2rem;
}

.floating-card:nth-child(3) {
  grid-column: 1 / -1;
  margin-top: -1rem;
}

.card-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.floating-card h3 {
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

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

/* Services Preview */
.services-preview {
  padding: 80px 0;
  background: var(--white);
}

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

.service-card {
  background: var(--background-light);
  padding: 2.5rem;
  border-radius: var(--border-radius);
  text-align: center;
  transition: var(--transition);
  border: 2px solid transparent;
}

.service-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-color);
  box-shadow: var(--shadow-lg);
}

.service-icon {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  display: block;
}

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

.service-card p {
  color: var(--text-light);
  margin-bottom: 1.5rem;
  line-height: 1.6;
  font-size: 0.8em;
}

.service-link {
  color: var(--accent-color);
  text-decoration: none;
  font-weight: 500;
  transition: var(--transition);
}

.service-link:hover {
  color: var(--primary-color);
}

/* Stats Section */
.stats {
  background: var(--primary-color);
  color: var(--white);
  padding: 60px 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  text-align: center;
}

.stat-number {
  font-size: 3rem;
  font-weight: 700;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 1.1rem;
  opacity: 0.9;
}

/* Page Header */
.page-header {
  background: var(--background-light);
  padding: 150px 0 80px;
  text-align: center;
}

.page-header h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.page-header p {
  font-size: 1.25rem;
  color: var(--text-light);
}

/* About Page Styles */
.about-content {
  padding: 80px 0;
}

.about-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 4rem;
  align-items: start;
}

.about-text p {
  margin-bottom: 1.5rem;
  color: var(--text-light);
  line-height: 1.7;
}

.about-skills {
  background: var(--background-light);
  padding: 2rem;
  border-radius: var(--border-radius);
}

.skill-category {
  margin-bottom: 2rem;
}

.skill-category h4 {
  margin-bottom: 1rem;
  color: var(--primary-color);
}

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

.skill-tag {
  background: var(--white);
  color: var(--text-dark);
  padding: 0.4rem 0.8rem;
  border-radius: 15px;
  font-size: 0.8rem;
  border: 1px solid var(--border-light);
}

.values {
  padding: 80px 0;
  background: var(--background-light);
}

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

.value-card {
  background: var(--white);
  padding: 2.5rem;
  border-radius: var(--border-radius);
  text-align: center;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.value-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.value-icon {
  font-size: 3rem;
  margin-bottom: 1.5rem;
}

/* Service Detail Pages */
.service-detail {
  padding: 60px 0;
}

.service-detail.alt {
  background: var(--background-light);
}

.service-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 4rem;
  align-items: start;
}

.service-icon-large {
  font-size: 4rem;
  margin-bottom: 1.5rem;
}

.service-features {
  list-style: none;
  margin: 2rem 0;
}

.service-features li {
  padding: 0.5rem 0;
  padding-left: 1.5rem;
  position: relative;
  color: var(--text-light);
}

.service-features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent-color);
  font-weight: bold;
}

.service-pricing {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-top: 2rem;
}

.price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-color);
}

.service-example {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

.service-example h4 {
  color: var(--accent-color);
  margin-bottom: 1rem;
}

/* Process Section */
.process {
  padding: 80px 0;
  background: var(--background-light);
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.process-step {
  text-align: center;
  padding: 2rem;
}

.step-number {
  width: 60px;
  height: 60px;
  background: var(--accent-color);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 auto 1.5rem;
}

/* Portfolio Styles */
.portfolio-filters {
  padding: 40px 0;
  background: var(--background-light);
}

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

.filter-btn {
  background: var(--white);
  color: var(--text-dark);
  border: 2px solid var(--border-light);
  padding: 0.75rem 1.5rem;
  border-radius: 25px;
  cursor: pointer;
  transition: var(--transition);
  font-weight: 500;
}

.filter-btn.active,
.filter-btn:hover {
  background: var(--accent-color);
  color: var(--white);
  border-color: var(--accent-color);
}

.portfolio-grid-section {
  padding: 80px 0;
}

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

.portfolio-item {
  background: var(--white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.portfolio-item:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.portfolio-image {
  height: 200px;
  background: var(--background-light);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.portfolio-placeholder {
  font-size: 4rem;
  opacity: 0.3;
}

.portfolio-content {
  padding: 2rem;
}

.portfolio-content h3 {
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.portfolio-content p {
  color: var(--text-light);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.tag {
  background: var(--background-light);
  color: var(--text-dark);
  padding: 0.3rem 0.8rem;
  border-radius: 15px;
  font-size: 0.8rem;
  font-weight: 500;
}

.project-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
}

.stat {
  text-align: center;
}

.stat-value {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent-color);
}

.stat-label {
  font-size: 0.8rem;
  color: var(--text-light);
}

/* Contact Styles */
.contact-section {
  padding: 80px 0;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
}

.contact-info h2 {
  margin-bottom: 1.5rem;
}

.contact-info p {
  color: var(--text-light);
  margin-bottom: 2.5rem;
  line-height: 1.7;
}

.contact-methods {
  display: grid;
  gap: 2rem;
}

.contact-method {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.contact-icon {
  font-size: 1.5rem;
  width: 50px;
  height: 50px;
  background: var(--background-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-details h3 {
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.contact-details p {
  margin-bottom: 0.25rem;
  color: var(--text-dark);
  font-weight: 500;
}

.contact-details span {
  color: var(--text-light);
  font-size: 0.9rem;
}

.contact-form-container {
  background: var(--background-light);
  padding: 2.5rem;
  border-radius: var(--border-radius);
}

.contact-form h3 {
  margin-bottom: 2rem;
  text-align: center;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--primary-color);
}

/* ========================================================================== */

.form-group select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

/* Add a custom wrapper for the select element */
.select-wrapper {
  position: relative;
}

/* Style the custom arrow */
.select-wrapper::after {
  content: "⌵"; /* Unicode character for a downward-pointing triangle */
  font-size: 1rem;
  color: var(--text-dark);
  position: absolute;
  right: 1.25rem; /* Adjust the position from the right */
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none; /* Allows clicks to pass through to the select element */
  transition: transform 0.2s ease-in-out;
}

/* Rotate the arrow when the select is active/focused */
.select-wrapper:focus-within::after {
  transform: translateY(-50%) rotate(180deg);
}

/* Adjust padding on the select to make room for the custom arrow */
.form-group select {
  padding-right: 2.5rem; /* Ensure there is enough space */
}
/* ======================================================================== */
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.875rem;
  border: 2px solid var(--border-light);
  border-radius: var(--border-radius);
  font-family: inherit;
  font-size: 1rem;
  transition: var(--transition);
  background: var(--white);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-color);
}

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

.form-status {
  margin-top: 1rem;
  padding: 1rem;
  border-radius: var(--border-radius);
  text-align: center;
  font-weight: 500;
}

.form-status.success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.form-status.error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* FAQ Section */
.faq {
  padding: 80px 0;
  background: var(--background-light);
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
}

.faq-item {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

.faq-item h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-size: 1.1rem;
}

.faq-item p {
  color: var(--text-light);
  line-height: 1.6;
}

/* CTA Section */
.cta {
  background: var(--primary-color);
  color: var(--white);
  padding: 80px 0;
  text-align: center;
}

.cta-content h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.cta-content p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  opacity: 0.9;
}

/* Footer */
.footer {
  background: var(--background-light);
  padding: 60px 0 20px;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 4rem;
  margin-bottom: 2rem;
}

.footer-brand {
  max-width: 300px;
}

.footer-logo {
  height: 60px;
  margin-bottom: 1rem;
}

.footer-brand p {
  color: var(--text-light);
  line-height: 1.6;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.footer-section h4 {
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.footer-section ul {
  list-style: none;
}

.footer-section li {
  margin-bottom: 0.5rem;
}

.footer-section a {
  color: var(--text-light);
  text-decoration: none;
  transition: var(--transition);
}

.footer-section a:hover {
  color: var(--accent-color);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--border-light);
  color: var(--text-light);
}

/* Responsive Design */
@media (max-width: 768px) {
  .nav-menu {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    padding: 2rem;
    box-shadow: var(--shadow);
    max-height: 0;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    overflow: hidden;
    z-index: 999;
  }

  .nav-menu.active {
    max-height: 400px; /* Adjust based on your menu items */
    opacity: 1;
    visibility: visible;
    padding: 2rem; /* Restore padding when active */
  }

  .hamburger {
    display: flex;
  }

  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
  }

  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2rem;
  }

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

  .hero-visual {
    grid-template-columns: 1fr;
  }

  .floating-card:nth-child(2) {
    margin-top: 0;
  }

  .floating-card:nth-child(3) {
    grid-column: 1;
    margin-top: 0;
  }

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

  .service-content {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .services-grid,
  .values-grid,
  .portfolio-grid,
  .faq-grid {
    grid-template-columns: 1fr;
  }

  .process-steps {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }

  .filter-buttons {
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 1rem;
  }

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

  h1 {
    font-size: 2.5rem;
  }
  h2 {
    font-size: 2rem;
  }
}

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

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

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

  .btn {
    width: 100%;
    max-width: 250px;
  }

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

  .project-stats {
    grid-template-columns: 1fr;
  }
}

/* Animation Classes */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: var(--transition);
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Portfolio Filter Animation */
.portfolio-item {
  transition: var(--transition);
}

.portfolio-item.hidden {
  opacity: 0;
  transform: scale(0.8);
  pointer-events: none;
}

/* Loading States */
.loading {
  position: relative;
  overflow: hidden;
}

.loading::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.4),
    transparent
  );
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% {
    left: -100%;
  }
  100% {
    left: 100%;
  }
}

/* Accessibility */
.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;
}

/* Focus States */
/* *:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
} */

/* Print Styles */
@media print {
  .header,
  .footer,
  .cta,
  .hero-buttons {
    display: none;
  }

  body {
    font-size: 12pt;
    line-height: 1.4;
  }

  .container {
    max-width: none;
    padding: 0;
  }
}
