/* FidelTech Corporate Website - Main Stylesheet */

/* ============================================
   CSS VARIABLES
   ============================================ */
:root {
  --primary: #0F172A;
  --primary-light: #1E293B;
  --secondary: #3B82F6;
  --secondary-dark: #2563EB;
  --accent: #10B981;
  --accent-dark: #059669;
  --text: #334155;
  --text-light: #64748B;
  --text-dark: #0F172A;
  --bg: #FFFFFF;
  --bg-light: #F8FAFC;
  --bg-dark: #F1F5F9;
  --border: #E2E8F0;
  --shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1), 0 10px 10px -5px rgba(0,0,0,0.04);
  --radius: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --transition: all 0.3s ease;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --max-width: 1280px;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--secondary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--secondary-dark); }

h1, h2, h3, h4, h5, h6 {
  color: var(--text-dark);
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 0.5em;
}

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

p { margin-bottom: 1rem; }

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

.section {
  padding: 5rem 0;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-header h2 {
  font-size: 2.25rem;
  margin-bottom: 1rem;
}

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

.section-label {
  display: inline-block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}

/* ============================================
   NAVBAR
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

.navbar.scrolled {
  box-shadow: var(--shadow-md);
}

.navbar-inner {
  display: flex;
  align-items: center;
  height: 72px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  gap: 1.5rem;
}

.navbar-menu { margin-left: auto; }

.navbar-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary);
}

.navbar-logo img { height: 40px; width: 40px; object-fit: contain; }

.footer-brand .navbar-logo img {
  height: 36px;
  width: 36px;
  object-fit: contain;
  background: white;
  border-radius: 8px;
  padding: 2px;
}

.navbar-logo span { color: var(--secondary); }

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

.navbar-menu a {
  color: var(--text);
  font-weight: 500;
  font-size: 0.9375rem;
  padding: 0.5rem 0;
  position: relative;
}

.navbar-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--secondary);
  transition: width 0.3s ease;
}

.navbar-menu a:hover::after,
.navbar-menu a.active::after { width: 100%; }

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

.lang-toggle {
  display: flex;
  align-items: center;
  background: var(--bg-dark);
  border-radius: 20px;
  padding: 2px;
  font-size: 0.8125rem;
  font-weight: 600;
}

.lang-toggle button {
  border: none;
  background: transparent;
  padding: 4px 12px;
  border-radius: 18px;
  cursor: pointer;
  color: var(--text-light);
  transition: var(--transition);
}

.lang-toggle button.active {
  background: var(--secondary);
  color: white;
}

.lang-switch-btn {
  border: 2px solid var(--secondary);
  background: transparent;
  color: var(--secondary);
  padding: 4px 14px;
  border-radius: 20px;
  font-size: 0.8125rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  letter-spacing: 0.5px;
  margin-left: 0.5rem;
}

.lang-switch-btn:hover {
  background: var(--secondary);
  color: white;
}

.footer .lang-switch-btn { display: none; }

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-dark);
  padding: 0.5rem;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.9375rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: var(--transition);
  text-decoration: none;
}

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

.btn-primary:hover {
  background: var(--secondary-dark);
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-outline {
  border-color: var(--secondary);
  color: var(--secondary);
  background: transparent;
}

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

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

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

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

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

.btn-lg {
  padding: 1rem 2rem;
  font-size: 1.0625rem;
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  padding: 10rem 0 6rem;
  background: linear-gradient(135deg, var(--primary) 0%, #1a2744 50%, var(--primary-light) 100%);
  color: white;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(59,130,246,0.15) 0%, transparent 70%);
  border-radius: 50%;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(16,185,129,0.1) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
}

.hero-label {
  display: inline-block;
  padding: 0.375rem 1rem;
  background: rgba(59,130,246,0.2);
  border: 1px solid rgba(59,130,246,0.3);
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 600;
  color: #93C5FD;
  margin-bottom: 1.5rem;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
  color: white;
  margin-bottom: 1.5rem;
}

.hero h1 span { color: #60A5FA; }

.hero p {
  font-size: 1.25rem;
  color: #CBD5E1;
  line-height: 1.7;
  margin-bottom: 2rem;
}

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

.hero-stats {
  display: flex;
  gap: 3rem;
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.hero-stat h3 {
  font-size: 2rem;
  color: white;
  margin-bottom: 0.25rem;
}

.hero-stat p {
  font-size: 0.875rem;
  color: #94A3B8;
  margin: 0;
}

/* ============================================
   CARDS
   ============================================ */
.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--secondary);
}

.card-icon {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #EFF6FF, #DBEAFE);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--secondary);
  margin-bottom: 1.25rem;
}

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

.card p {
  color: var(--text-light);
  font-size: 0.9375rem;
  line-height: 1.6;
}

/* ============================================
   GRID LAYOUTS
   ============================================ */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }

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

/* ============================================
   PRODUCTS SECTION
   ============================================ */
.product-showcase {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.product-image {
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  background: var(--bg-dark);
  aspect-ratio: 16/10;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--text-light);
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2rem;
}

.product-image-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--primary) 0%, #1a2744 50%, var(--primary-light) 100%);
  color: white;
  padding: 2rem;
}

.product-image-placeholder i {
  font-size: 4rem;
  color: #60A5FA;
}

.product-image-placeholder span {
  font-size: 1.25rem;
  font-weight: 700;
  color: #CBD5E1;
  letter-spacing: 0.05em;
}

.product-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: linear-gradient(135deg, #EFF6FF, #DBEAFE);
  color: var(--secondary);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 20px;
  margin-bottom: 0.75rem;
}

.product-info h3 {
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
}

.product-info .tagline {
  color: var(--secondary);
  font-weight: 600;
  margin-bottom: 1rem;
}

.feature-list {
  list-style: none;
  margin: 1.5rem 0;
}

.feature-list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 0;
  font-size: 0.9375rem;
}

.feature-list li i {
  color: var(--accent);
  font-size: 1rem;
  width: 20px;
}

/* ============================================
   BLOG SECTION
   ============================================ */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.blog-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
}

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

.blog-card-image {
  aspect-ratio: 16/9;
  background: var(--bg-dark);
  overflow: hidden;
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-card-body {
  padding: 1.5rem;
}

.blog-card-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.8125rem;
  color: var(--text-light);
  margin-bottom: 0.75rem;
}

.blog-card-meta .category {
  color: var(--secondary);
  font-weight: 600;
}

.blog-card h3 {
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.blog-card h3 a {
  color: var(--text-dark);
}

.blog-card h3 a:hover {
  color: var(--secondary);
}

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

/* ============================================
   CTA SECTION
   ============================================ */
.cta-section {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
  text-align: center;
  padding: 5rem 0;
}

.cta-section h2 {
  color: white;
  font-size: 2.25rem;
  margin-bottom: 1rem;
}

.cta-section p {
  color: #CBD5E1;
  font-size: 1.125rem;
  max-width: 600px;
  margin: 0 auto 2rem;
}

/* ============================================
   ABOUT SECTION
   ============================================ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.about-image {
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  aspect-ratio: 4/3;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 4rem;
}

/* ============================================
   CONTACT SECTION
   ============================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
}

.contact-form {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
}

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

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  color: var(--text);
  transition: var(--transition);
  background: var(--bg);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
}

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

.contact-info-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem;
  border-radius: var(--radius);
  background: var(--bg-light);
  margin-bottom: 1rem;
}

.contact-info-card i {
  font-size: 1.25rem;
  color: var(--secondary);
  margin-top: 0.25rem;
  width: 24px;
}

.contact-info-card h4 {
  font-size: 0.9375rem;
  margin-bottom: 0.25rem;
}

.contact-info-card p {
  font-size: 0.875rem;
  color: var(--text-light);
  margin: 0;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--primary);
  color: #94A3B8;
  padding: 4rem 0 2rem;
}

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

.footer-brand p {
  margin-top: 1rem;
  font-size: 0.875rem;
  line-height: 1.7;
}

.footer-social {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.footer-social a {
  width: 36px;
  height: 36px;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94A3B8;
  transition: var(--transition);
}

.footer-social a:hover {
  background: var(--secondary);
  color: white;
}

.footer h4 {
  color: white;
  font-size: 1rem;
  margin-bottom: 1.25rem;
}

.footer-links {
  list-style: none;
}

.footer-links li { margin-bottom: 0.75rem; }

.footer-links a {
  color: #94A3B8;
  font-size: 0.875rem;
}

.footer-links a:hover { color: white; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8125rem;
}

.footer-bottom a { color: #94A3B8; }
.footer-bottom a:hover { color: white; }

/* ============================================
   BREADCRUMB
   ============================================ */
.breadcrumb {
  padding: 1rem 0;
  font-size: 0.875rem;
}

.breadcrumb a { color: var(--text-light); }
.breadcrumb a:hover { color: var(--secondary); }
.breadcrumb span { color: var(--text-light); margin: 0 0.5rem; }
.breadcrumb .current { color: var(--text-dark); font-weight: 500; }

/* ============================================
   PAGE HEADER
   ============================================ */
.page-header {
  padding: 8rem 0 3rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
}

.page-header h1 {
  color: white;
  font-size: 2.75rem;
  margin-bottom: 0.75rem;
}

.page-header p {
  color: #CBD5E1;
  font-size: 1.125rem;
  max-width: 600px;
}

/* ============================================
   PAGINATION
   ============================================ */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 3rem;
}

.pagination a, .pagination span {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text);
  transition: var(--transition);
}

.pagination a:hover { border-color: var(--secondary); color: var(--secondary); }
.pagination .active { background: var(--secondary); color: white; border-color: var(--secondary); }

/* ============================================
   ALERTS & MESSAGES
   ============================================ */
.alert {
  padding: 1rem 1.5rem;
  border-radius: var(--radius);
  margin-bottom: 1.5rem;
  font-size: 0.9375rem;
}

.alert-success { background: #ECFDF5; color: #065F46; border: 1px solid #A7F3D0; }
.alert-error { background: #FEF2F2; color: #991B1B; border: 1px solid #FECACA; }
.alert-info { background: #EFF6FF; color: #1E40AF; border: 1px solid #BFDBFE; }

/* ============================================
   COOKIE CONSENT
   ============================================ */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--primary);
  color: white;
  padding: 1.25rem;
  z-index: 9999;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.cookie-consent.show { transform: translateY(0); }

.cookie-consent-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.cookie-consent p {
  font-size: 0.875rem;
  color: #CBD5E1;
  margin: 0;
}

.cookie-consent p a { color: #60A5FA; }

.cookie-consent-buttons {
  display: flex;
  gap: 0.75rem;
  flex-shrink: 0;
}

/* ============================================
   LOADING
   ============================================ */
.loading-spinner {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid var(--border);
  border-top-color: var(--secondary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================
   ANIMATIONS
   ============================================ */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.slide-in-left {
  opacity: 0;
  transform: translateX(-30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.slide-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.slide-in-right {
  opacity: 0;
  transform: translateX(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.slide-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .hero h1 { font-size: 2.75rem; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .product-showcase { grid-template-columns: 1fr; gap: 2rem; }
  .about-grid { grid-template-columns: 1fr; gap: 2rem; }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .hero { padding: 8rem 0 4rem; }
  .hero h1 { font-size: 2.25rem; }
  .hero-stats { flex-direction: column; gap: 1.5rem; }
  .section { padding: 3.5rem 0; }
  .navbar-menu { display: none; }
  .navbar-menu.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: white;
    padding: 1rem;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
    z-index: 100;
  }
  .lang-switch-btn { margin-left: auto; }
  .mobile-toggle { display: block; }
  .services-grid { grid-template-columns: 1fr; }
  .blog-grid { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
  .cookie-consent-inner { flex-direction: column; text-align: center; }
  .page-header { padding: 7rem 0 2rem; }
  .page-header h1 { font-size: 2rem; }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  .section-header h2 { font-size: 1.75rem; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 1.75rem; }
  .hero-buttons { flex-direction: column; }
  .hero-buttons .btn { width: 100%; }
  .btn-lg { padding: 0.875rem 1.5rem; }
}
