/* ==========================================================================
   eDataWorker CSS Stylesheet - Updated Modern & Mobile-Responsive
   ========================================================================== */

/* Modern CSS Reset & Variable Definitions */
:root {
  --bg-primary: #0f172a;       /* Deep slate background */
  --bg-secondary: #1e293b;     /* Card background */
  --accent: #38bdf8;           /* Tech cyan primary highlight */
  --accent-hover: #0ea5e9;
  --text-main: #f8fafc;        /* Off-white */
  --text-muted: #94a3b8;       /* Muted gray */
  --border-color: #334155;
  --success: #10b981;          /* Green for positive validation elements */
  --font-stack: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-family: var(--font-stack);
  background-color: var(--bg-primary);
  color: var(--text-main);
}

body {
  line-height: 1.6;
  overflow-x: hidden;
}

/* Reusable Global Containers */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 24px;
}

.section-header {
  text-align: center;
  margin-bottom: 50px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.section-header h2 {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 15px;
}

.section-header p {
  color: var(--text-muted);
  font-size: 1.1rem;
}

/* Navigation Bar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition-smooth);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
}

.nav-logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-main);
  text-decoration: none;
  letter-spacing: -0.025em;
}

.nav-logo .dot {
  color: var(--accent);
}

.nav-menu {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 24px;
}

.nav-menu a {
  text-decoration: none;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.95rem;
  transition: var(--transition-smooth);
}

.nav-menu a:hover {
  color: var(--text-main);
}

.nav-menu .nav-cta {
  background-color: var(--accent);
  color: var(--bg-primary);
  padding: 8px 18px;
  border-radius: 8px;
  font-weight: 600;
}

.nav-menu .nav-cta:hover {
  background-color: var(--accent-hover);
  transform: translateY(-1px);
}

/* Services dropdown (native <details>, no JS required) */
.nav-item-dropdown {
  position: relative;
}

.nav-item-dropdown summary {
  list-style: none;
  cursor: pointer;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.95rem;
  transition: var(--transition-smooth);
}

.nav-item-dropdown summary::-webkit-details-marker {
  display: none;
}

.nav-item-dropdown summary::after {
  content: " \f107";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: 0.7rem;
  margin-left: 4px;
}

.nav-item-dropdown summary:hover {
  color: var(--text-main);
}

.nav-item-dropdown[open] summary {
  color: var(--text-main);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 16px);
  left: 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 8px;
  min-width: 250px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.45);
  z-index: 1001;
}

.dropdown-menu a {
  display: block;
  padding: 9px 12px;
  border-radius: 6px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.dropdown-menu a:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-main);
}

/* Trimmed service teaser cards on homepage */
.service-teaser p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 18px;
}

.service-teaser .learn-more {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: var(--transition-smooth);
}

.service-teaser .learn-more:hover {
  gap: 10px;
}

/* Hero Header */
.hero {
  padding-top: 160px;
  padding-bottom: 100px;
  background: radial-gradient(circle at top right, rgba(56, 189, 248, 0.08), transparent 45%);
  text-align: center;
}

.hero-container {
  max-width: 850px;
  margin: 0 auto;
  padding: 0 24px;
}

.badge {
  display: inline-block;
  background-color: rgba(56, 189, 248, 0.1);
  color: var(--accent);
  padding: 6px 16px;
  border-radius: 30px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 24px;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.hero h1 .highlight {
  color: var(--accent);
}

.hero-subtext {
  color: var(--text-muted);
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1.6;
  margin-bottom: 35px;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 40px;
}

.cta, .cta-outline {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition-smooth);
}

.cta {
  background-color: var(--accent);
  color: var(--bg-primary);
}

.cta:hover {
  background-color: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(56, 189, 248, 0.15);
}

.cta-outline {
  border: 1px solid var(--border-color);
  color: var(--text-main);
  background-color: transparent;
}

.cta-outline:hover {
  background-color: rgba(255, 255, 255, 0.05);
  border-color: var(--text-muted);
  transform: translateY(-2px);
}

.hero-socials {
  display: flex;
  justify-content: center;
  gap: 24px;
}

.hero-socials a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition-smooth);
}

.hero-socials a:hover {
  color: var(--accent);
}

/* About / Core Advantages Grid */
.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.about-card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 32px;
  transition: var(--transition-smooth);
}

.about-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
}

.card-icon {
  font-size: 2rem;
  color: var(--accent);
  margin-bottom: 20px;
  display: inline-block;
}

.about-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.about-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Service Blocks & Portfolios Grid */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 30px;
  display: flex;
  flex-direction: column;
}

.card h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.card ul li {
  position: relative;
  padding-left: 20px;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.card ul li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent);
}

/* Pricing Section Rules */
.pricing-grid {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.price-card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 40px 32px;
  text-align: center;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: var(--transition-smooth);
}

.price-card.featured {
  border: 2px solid var(--accent);
  transform: scale(1.02);
}

.popular-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--accent);
  color: var(--bg-primary);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 20px;
  letter-spacing: 0.05em;
}

.price-card h3 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.price-card .price {
  font-size: 3rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 4px;
}

.price-card .price .unit {
  font-size: 1.1rem;
  color: var(--text-muted);
  font-weight: 500;
}

.minimum-term {
  font-size: 0.85rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 24px;
}

.price-card ul {
  list-style: none;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 30px;
}

.price-card ul li {
  font-size: 0.95rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 10px;
}

.price-card ul li::before {
  content: "\f00c";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  color: var(--success);
}

.price-cta {
  margin-top: auto;
  display: block;
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  text-decoration: none;
  padding: 12px;
  border-radius: 8px;
  font-weight: 600;
  transition: var(--transition-smooth);
}

.price-card.featured .price-cta {
  background-color: var(--accent);
  color: var(--bg-primary);
  border: none;
}

.price-card.featured .price-cta:hover {
  background-color: var(--accent-hover);
}

.price-cta:hover {
  background-color: rgba(255, 255, 255, 0.10);
  border-color: var(--text-muted);
}

/* Portfolio Work Elements */
.portfolio-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center; /* Centers the cards horizontally */
  gap: 24px;
}

/* On Desktop: Force the items to take up roughly 1/3 of the space so they break 3 and 2 */
.portfolio-grid .portfolio-card {
  flex: 1 1 calc(33.333% - 24px);
  min-width: 300px; /* Prevents them from shrinking too small */
  max-width: 380px; /* Ensures the bottom two cards stay an aesthetic size instead of stretching too wide */
}

/* On Mobile/Tablet: Let them stack normally */
@media (max-width: 768px) {
  .portfolio-grid .portfolio-card {
    flex: 1 1 100%;
    max-width: 100%;
  }
}

.portfolio-card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 30px;
  transition: var(--transition-smooth);
}

.portfolio-card:hover {
  border-color: var(--accent);
}

.tech-tag {
  display: inline-block;
  font-size: 0.75rem;
  background-color: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
  padding: 4px 10px;
  border-radius: 4px;
  font-weight: 600;
  margin-bottom: 14px;
}

.portfolio-card h3 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.portfolio-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 20px;
}

.portfolio-links {
  display: flex;
  gap: 16px;
}

.portfolio-links a {
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 6px;
}

.portfolio-links a:hover {
  text-decoration: underline;
}

/* Testimonial & Logo Galleries */
.testimonial-gallery, .logo-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
}

.testimonial-gallery img, .logo-gallery img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid var(--border-color);
  transition: var(--transition-smooth);
}

.testimonial-gallery img:hover, .logo-gallery img:hover {
  transform: scale(1.03);
  border-color: var(--accent);
}

/* Contact Wrapper & Layout */
.contact-wrapper {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  overflow: hidden;
}

.contact-details {
  padding: 50px;
  background-image: radial-gradient(circle at bottom left, rgba(56, 189, 248, 0.05), transparent 60%);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.contact-details h2 {
  font-size: 2.2rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 15px;
}

.contact-details p {
  color: var(--text-muted);
  margin-bottom: 30px;
}

.contact-info-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-info-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.contact-info-list li i {
  color: var(--accent);
  font-size: 1.1rem;
}

.contact-form {
  padding: 50px;
  border-left: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.contact-form input, .contact-form textarea {
  width: 100%;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 14px;
  border-radius: 8px;
  font-family: var(--font-stack);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition-smooth);
}

.contact-form input:focus, .contact-form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}

.submit-btn {
  background-color: var(--accent);
  color: var(--bg-primary);
  border: none;
  padding: 14px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.submit-btn:hover {
  background-color: var(--accent-hover);
  transform: translateY(-1px);
}

/* Style adjustment for the Turnstile widget wrapper */
.cf-turnstile {
  margin: 15px 0;
  display: flex;
  justify-content: flex-start; /* Or use center if your form is centered */
}

/* Enlarged Image Modals/Popups */
.popup {
  display: none;
  position: fixed;
  z-index: 10001;
  padding-top: 60px;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(15, 23, 42, 0.9);
}

.popup-content {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 700px;
  border-radius: 12px;
  border: 1px solid var(--border-color);
}

.popup-close {
  position: absolute;
  top: 15px;
  right: 35px;
  color: var(--text-main);
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.popup-close:hover {
  color: var(--accent);
}

/* Footer Section */
footer {
  border-top: 1px solid var(--border-color);
  text-align: center;
  padding: 40px 0;
}

footer p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Media Queries for Responsive Design */
@media (max-width: 968px) {
  .contact-wrapper {
    grid-template-columns: 1fr;
  }
  .contact-form {
    border-left: none;
    border-top: 1px solid var(--border-color);
    padding: 30px;
  }
  .contact-details {
    padding: 30px;
  }
}

@media (max-width: 768px) {
  .nav-menu {
    display: none; /* Add responsive layout toggles here in script.js as needed */
  }
  .dropdown-menu {
    position: static;
    box-shadow: none;
    border: none;
    background: transparent;
    padding-left: 10px;
  }
  .hero h1 {
    font-size: 2.5rem;
  }
  .hero-subtext {
    font-size: 1.1rem;
  }
  .section-header h2 {
    font-size: 2rem;
  }
  .container {
    padding: 50px 16px;
  }
}
