/* ==============================
   SAPI — Design System
   Corporate Navy + Warm Accents
   ============================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* --- CSS Variables --- */
:root {
  --navy: #1B3A5C;
  --navy-dark: #0D1B2A;
  --charcoal: #2D3748;
  --steel: #3D6B99;
  --steel-light: #5B9FE6;
  --amber: #F59E0B;
  --amber-dark: #D97706;
  --amber-light: #FCD34D;
  --white: #FFFFFF;
  --gray-50: #F9FAFB;
  --gray-100: #F3F4F6;
  --gray-200: #E5E7EB;
  --gray-300: #D1D5DB;
  --gray-500: #6B7280;
  --gray-700: #374151;
  --gray-900: #111827;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --max-width: 1200px;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, .1), 0 2px 4px -2px rgba(0, 0, 0, .1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, .1), 0 4px 6px -4px rgba(0, 0, 0, .1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, .1), 0 8px 10px -6px rgba(0, 0, 0, .1);
  --transition: all .3s cubic-bezier(.4, 0, .2, 1);
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font);
  color: var(--gray-700);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--navy);
  line-height: 1.2;
  font-weight: 700;
}

h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
}

h2 {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
}

h3 {
  font-size: clamp(1.2rem, 3vw, 1.5rem);
}

p {
  margin-bottom: 1rem;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 80px 0;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .95rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: var(--transition);
  font-family: var(--font);
}

.btn-primary {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.btn-primary:hover {
  background: var(--steel);
  border-color: var(--steel);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-amber {
  background: var(--amber);
  color: var(--navy-dark);
  border-color: var(--amber);
}

.btn-amber:hover {
  background: var(--amber-dark);
  border-color: var(--amber-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: var(--white);
}

.btn-outline:hover {
  background: var(--white);
  color: var(--navy);
}

.btn-outline-navy {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}

.btn-outline-navy:hover {
  background: var(--navy);
  color: var(--white);
}

/* --- NAVBAR --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: var(--white);
  border-bottom: 3px solid var(--amber);
  transition: var(--transition);
}

.navbar.scrolled {
  box-shadow: var(--shadow-lg);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  padding-bottom: 12px;
}

.navbar .logo img {
  height: 48px;
  width: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-links a {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: .85rem;
  font-weight: 500;
  color: var(--charcoal);
  letter-spacing: .3px;
  text-transform: uppercase;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--navy);
  background: var(--gray-100);
}

.nav-links .btn-amber {
  text-transform: uppercase;
  padding: 8px 20px;
  font-size: .8rem;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-right .lang-link {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: .8rem;
  color: var(--gray-500);
}

.nav-right .lang-link img {
  width: 22px;
  height: auto;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  background: none;
  border: none;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2.5px;
  background: var(--navy);
  border-radius: 2px;
  transition: var(--transition);
}

.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(5px, -5px);
}

/* --- HERO --- */
.hero {
  min-height: 600px;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--charcoal) 0%, var(--navy-dark) 60%, var(--navy) 100%);
  position: relative;
  overflow: hidden;
  margin-top: 75px;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../images/hero-bg.png') center/cover no-repeat;
  opacity: .3;
}

.hero .container {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-content h1 {
  color: var(--white);
  margin-bottom: 20px;
}

.hero-content h1 .highlight {
  color: var(--amber);
}

.hero-content p {
  color: var(--gray-300);
  font-size: 1.1rem;
  margin-bottom: 32px;
  line-height: 1.7;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-image {
  text-align: center;
}

.hero-image img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-xl);
}

/* --- STATS BAR --- */
.stats-bar {
  background: var(--navy);
  padding: 40px 0;
}

.stats-bar .container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  text-align: center;
}

.stat-item .stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--amber);
  display: block;
}

.stat-item .stat-label {
  color: var(--gray-300);
  font-size: .9rem;
  font-weight: 500;
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* --- SECTION HEADER --- */
.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header .overline {
  color: var(--amber);
  font-weight: 600;
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 8px;
  display: block;
}

.section-header h2 {
  margin-bottom: 16px;
}

.section-header p {
  color: var(--gray-500);
  max-width: 600px;
  margin: 0 auto;
}

/* --- SERVICE CARDS --- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  justify-items: center;
}

.values-grid .value-card {
  width: 100%;
}

.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 40px 30px;
  border: 1px solid var(--gray-200);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--navy), var(--amber));
  transform: scaleX(0);
  transition: var(--transition);
  transform-origin: left;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-xl);
  border-color: transparent;
}

.service-card:hover::before {
  transform: scaleX(1);
}

.service-card .icon {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--navy), var(--steel));
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  font-size: 28px;
  color: var(--white);
}

.service-card h3 {
  margin-bottom: 12px;
}

.service-card p {
  color: var(--gray-500);
  font-size: .95rem;
  margin-bottom: 16px;
}

.service-card ul {
  padding: 0;
}

.service-card ul li {
  padding: 6px 0;
  font-size: .9rem;
  color: var(--gray-500);
  display: flex;
  align-items: center;
  gap: 8px;
}

.service-card ul li::before {
  content: '✓';
  color: var(--amber);
  font-weight: 700;
}

.service-card .card-link {
  color: var(--navy);
  font-weight: 600;
  font-size: .9rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.service-card .card-link:hover {
  color: var(--amber);
  gap: 10px;
}

/* --- CTA SECTION --- */
.cta-section {
  background: linear-gradient(135deg, var(--navy-dark), var(--navy));
  padding: 80px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(245, 158, 11, .15) 0%, transparent 60%);
}

.cta-section .container {
  position: relative;
  z-index: 2;
}

.cta-section h2 {
  color: var(--white);
  margin-bottom: 16px;
}

.cta-section p {
  color: var(--gray-300);
  margin-bottom: 32px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* --- TESTIMONIALS --- */
.testimonials {
  background: var(--gray-50);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.testimonial-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  border-left: 4px solid var(--amber);
}

.testimonial-card:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-4px);
}

.testimonial-card .quote {
  font-style: italic;
  color: var(--gray-700);
  font-size: .95rem;
  margin-bottom: 20px;
  line-height: 1.7;
}

.testimonial-card .quote::before {
  content: '"';
  font-size: 3rem;
  color: var(--amber);
  line-height: 0;
  margin-right: 4px;
  vertical-align: -12px;
}

.testimonial-card .author {
  font-weight: 700;
  color: var(--navy);
  font-size: .9rem;
}

.testimonial-card .role {
  color: var(--gray-500);
  font-size: .8rem;
}

/* --- CLIENTS GRID --- */
.clients-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 20px;
  align-items: center;
}

.client-logo {
  background: var(--white);
  border-radius: var(--radius-sm);
  padding: 20px;
  border: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100px;
  transition: var(--transition);
}

.client-logo:hover {
  box-shadow: var(--shadow);
  border-color: var(--amber);
  transform: scale(1.05);
}

.client-logo img {
  max-height: 60px;
  max-width: 100%;
  object-fit: contain;
  filter: grayscale(60%);
  transition: var(--transition);
}

.client-logo:hover img {
  filter: grayscale(0);
}

/* --- CONTACT FORM --- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: .85rem;
  color: var(--navy);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: .5px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: .95rem;
  transition: var(--transition);
  background: var(--white);
  color: var(--gray-900);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(27, 58, 92, .1);
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.form-message {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  margin-top: 12px;
  font-size: .9rem;
  display: none;
}

.form-message.success {
  background: #D1FAE5;
  color: #065F46;
  display: block;
}

.form-message.error {
  background: #FEE2E2;
  color: #991B1B;
  display: block;
}

.contact-info-cards {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.contact-info-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 24px;
  background: var(--gray-50);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.contact-info-card:hover {
  background: var(--white);
  box-shadow: var(--shadow);
}

.contact-info-card .info-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--navy), var(--steel));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: var(--white);
}

.contact-info-card h4 {
  color: var(--navy);
  font-size: .9rem;
  margin-bottom: 4px;
}

.contact-info-card p {
  color: var(--gray-500);
  font-size: .9rem;
  margin: 0;
}

.contact-info-card a {
  color: var(--steel);
}

.contact-info-card a:hover {
  color: var(--amber);
}

/* WhatsApp Button */
.btn-whatsapp {
  background: #25D366;
  color: var(--white);
  border-color: #25D366;
  font-size: 1rem;
  padding: 16px 32px;
}

.btn-whatsapp:hover {
  background: #128C7E;
  border-color: #128C7E;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.whatsapp-float {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 999;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25D366;
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  box-shadow: var(--shadow-lg);
  transition: var(--transition);
  cursor: pointer;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: var(--shadow-xl);
}

/* --- MAP --- */
.map-wrapper {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.map-wrapper iframe {
  width: 100%;
  height: 350px;
  border: 0;
}

/* --- PAGE HEADER --- */
.page-header {
  background: linear-gradient(135deg, var(--navy-dark), var(--navy));
  padding: 120px 0 60px;
  text-align: center;
  margin-top: 75px;
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../images/hero-bg.png') center/cover no-repeat;
  opacity: .15;
}

.page-header .container {
  position: relative;
  z-index: 2;
}

.page-header h1 {
  color: var(--white);
  margin-bottom: 12px;
}

.page-header p {
  color: var(--gray-300);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

/* --- TWO COLUMNS --- */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.two-col.reverse {
  direction: rtl;
}

.two-col.reverse>* {
  direction: ltr;
}

/* --- TIMELINE --- */
.timeline {
  position: relative;
  padding-left: 40px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--gray-200);
  border-radius: 2px;
}

.timeline-item {
  position: relative;
  padding-bottom: 32px;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -32px;
  top: 4px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--amber);
  border: 3px solid var(--white);
  box-shadow: 0 0 0 3px var(--amber);
}

.timeline-item h4 {
  color: var(--navy);
  margin-bottom: 4px;
}

.timeline-item p {
  color: var(--gray-500);
  font-size: .9rem;
  margin: 0;
}

/* --- VALUES --- (defined above) */

.value-card {
  text-align: center;
  padding: 32px 24px;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--gray-200);
  transition: var(--transition);
}

.value-card:hover {
  border-color: var(--amber);
  box-shadow: var(--shadow);
}

.value-card .value-icon {
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.value-card h4 {
  margin-bottom: 8px;
}

.value-card p {
  color: var(--gray-500);
  font-size: .9rem;
  margin: 0;
}

/* --- CERTIFICATION BADGE --- */
.cert-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--gray-50);
  padding: 16px 24px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--gray-200);
}

.cert-badge .badge-icon {
  font-size: 2rem;
}

.cert-badge h4 {
  color: var(--navy);
  font-size: .9rem;
  margin-bottom: 2px;
}

.cert-badge p {
  color: var(--gray-500);
  font-size: .8rem;
  margin: 0;
}

/* --- EXPERIENCE GRID --- */
.exp-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.exp-card {
  padding: 32px;
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
  transition: var(--transition);
}

.exp-card:hover {
  box-shadow: var(--shadow-lg);
  border-color: var(--steel-light);
}

.exp-card h3 {
  color: var(--navy);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.exp-card h3 .icon {
  color: var(--amber);
  font-size: 1.4rem;
}

.exp-card p {
  color: var(--gray-500);
  font-size: .95rem;
  margin-bottom: 16px;
}

.exp-card .tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.exp-card .tech-tag {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: .78rem;
  font-weight: 500;
  background: var(--gray-100);
  color: var(--navy);
}

/* --- FOOTER --- */
.footer {
  background: var(--navy-dark);
  color: var(--gray-300);
  padding: 60px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand p {
  font-size: .9rem;
  line-height: 1.7;
  margin-top: 16px;
}

.footer-brand img {
  height: 40px;
  filter: brightness(0) invert(1);
}

.footer h4 {
  color: var(--white);
  font-size: .9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 16px;
}

.footer ul li {
  margin-bottom: 10px;
}

.footer ul li a {
  color: var(--gray-300);
  font-size: .9rem;
}

.footer ul li a:hover {
  color: var(--amber);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .1);
  padding: 20px 0;
  text-align: center;
  font-size: .85rem;
  color: var(--gray-500);
}

/* --- RESPONSIVE --- */
@media (max-width:1024px) {
  .hero .container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-image {
    display: none;
  }

  .stats-bar .container {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .exp-grid {
    grid-template-columns: 1fr;
  }

  .two-col {
    grid-template-columns: 1fr;
  }

  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .values-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width:768px) {
  section {
    padding: 60px 0;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 75px;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--white);
    flex-direction: column;
    padding: 24px;
    gap: 0;
    overflow-y: auto;
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links a {
    padding: 14px;
    font-size: 1rem;
    width: 100%;
    text-align: left;
    border-bottom: 1px solid var(--gray-100);
  }

  .hamburger {
    display: flex;
  }

  .hero {
    min-height: auto;
    padding: 60px 0;
  }

  .hero-buttons {
    justify-content: center;
  }

  .stats-bar .container {
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .testimonials-grid {
    grid-template-columns: 1fr;
  }

  .clients-grid {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  }
}

@media (max-width:480px) {
  .stats-bar .container {
    grid-template-columns: 1fr;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }

  .stat-item .stat-number {
    font-size: 2rem;
  }
}

/* --- ANIMATIONS --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-in {
  animation: fadeInUp .6s ease forwards;
}

.animate-delay-1 {
  animation-delay: .1s;
}

.animate-delay-2 {
  animation-delay: .2s;
}

.animate-delay-3 {
  animation-delay: .3s;
}

/* visible on scroll */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .6s ease, transform .6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}