/* Hydindata — Professional Business Design
   Clean white background with blue accents
   Monospace programmer font for technical credibility
   Optimized for business and professional contexts
*/

/* ============================================
   CSS VARIABLES - BUSINESS THEME
   ============================================ */
:root {
  /* Colors - Professional White & Blue */
  --bg: #ffffff;
  --bg-subtle: #f8fafc;
  --surface: #ffffff;
  --surface-raised: #fafbfc;
  
  /* Blue palette - Professional */
  --primary: #0066cc;        /* Deep blue */
  --primary-light: #4d94ff;  /* Bright blue */
  --primary-dark: #004d99;   /* Navy blue */
  --primary-pale: #e6f2ff;   /* Very light blue */
  
  /* Text colors */
  --text: #1a202c;           /* Near black */
  --text-muted: #64748b;     /* Slate gray */
  --text-light: #94a3b8;     /* Light gray */
  
  /* Accent colors */
  --accent: #0066cc;
  --accent-light: #e6f2ff;
  --success: #059669;
  
  /* Borders & shadows */
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.08);
  
  /* Layout */
  --radius: 8px;
  --radius-sm: 4px;
  --radius-lg: 12px;
  --container: 1120px;
  --gap: 20px;
  --line: 1.6;
  
  /* Focus state */
  --focus: 0 0 0 3px rgba(0, 102, 204, 0.2);
}

/* ============================================
   BASE STYLES
   ============================================ */
* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  /* Professional sans-serif font stack - Inter primary */
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro', 'Segoe UI', 
               'Roboto', 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: var(--line);
  font-size: 15px;
  position: relative;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  transition: color 0.15s ease;
}

p {
  margin: 0 0 16px;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */
h1, h2, h3, h4 {
  line-height: 1.3;
  margin: 0 0 16px;
  font-weight: 600;
  color: var(--text);
}

h1 {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

h3 {
  font-size: 1.25rem;
}

h4 {
  font-size: 1rem;
}

/* ============================================
   NETWORK WEB BACKGROUND
   ============================================ */

/* SVG network pattern with connected nodes */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background-color: var(--bg);
  background-image: url('../img/network-bg.svg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.35;
  animation: networkPulse 15s ease-in-out infinite;
}

@keyframes networkPulse {
  0%, 100% {
    opacity: 0.35;
  }
  50% {
    opacity: 0.45;
  }
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  body::before {
    animation: none;
    opacity: 0.35;
  }
}

/* Mobile optimization */
@media (max-width: 768px) {
  body::before {
    background-size: 150% auto;
    opacity: 0.25;
  }
}

/* ============================================
   LAYOUT
   ============================================ */
.container {
  width: min(var(--container), calc(100% - 32px));
  margin: 0 auto;
}

.section {
  padding: 64px 0;
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text);
}

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

.brand-mark {
  border-radius: var(--radius-sm);
}

.brand-name {
  font-size: 1rem;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-toggle {
  display: none;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  border-radius: var(--radius);
  padding: 10px 14px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
}

.nav-toggle:hover {
  background: var(--bg-subtle);
}

.nav-toggle:focus-visible {
  outline: none;
  box-shadow: var(--focus);
}

.nav-toggle-label {
  font-weight: 600;
  font-size: 0.9rem;
}

.nav-toggle-icon {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 20px;
  height: 16px;
  margin-left: 8px;
}

.nav-toggle-icon span {
  display: block;
  width: 100%;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Hamburger transforms to X when open */
.nav-toggle[aria-expanded="true"] .nav-toggle-icon span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-icon span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-icon span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-menu a {
  text-decoration: none;
  padding: 10px 16px;
  border-radius: var(--radius);
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
}

.nav-menu a[aria-current="page"] {
  color: var(--primary);
  background: var(--accent-light);
}

.nav-menu a:hover {
  color: var(--primary);
  background: var(--bg-subtle);
}

/* Keep buttons styled correctly in nav */
.nav-menu .btn-primary {
  color: white;
  background: var(--primary);
}

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

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border-radius: var(--radius);
  padding: 10px 20px;
  border: 1px solid var(--border);
  cursor: pointer;
  user-select: none;
  font-weight: 600;
  font-size: 0.9rem;
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  transition: all 0.15s ease;
}

.btn:hover {
  background: var(--bg-subtle);
  border-color: var(--text-muted);
}

.btn:focus-visible {
  outline: none;
  box-shadow: var(--focus);
}

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

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

.btn-ghost {
  background: transparent;
  border-color: var(--primary);
  color: var(--primary);
}

.btn-ghost:hover {
  background: var(--accent-light);
  border-color: var(--primary);
}

.btn-small {
  padding: 6px 12px;
  font-size: 0.85rem;
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.skip-link {
  position: absolute;
  left: -999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.skip-link:focus {
  position: fixed;
  left: 16px;
  top: 16px;
  width: auto;
  height: auto;
  padding: 12px 20px;
  background: var(--primary);
  color: white;
  border-radius: var(--radius);
  z-index: 999;
  box-shadow: var(--shadow-lg);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* ============================================
   HOMEPAGE HERO
   ============================================ */
.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 48px;
  align-items: center;
}

.hero-card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow);
}

.hero-card-footer {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border-light);
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.pill {
  font-size: 0.75rem;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--accent-light);
  color: var(--primary);
  border: 1px solid var(--primary-pale);
  font-weight: 600;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.stat-value {
  font-weight: 600;
  color: var(--text);
  font-size: 0.95rem;
}

/* ============================================
   CONTENT SECTIONS
   ============================================ */
.page-hero {
  padding-top: 80px;
  padding-bottom: 48px;
  background: linear-gradient(180deg, var(--bg-subtle) 0%, var(--bg) 100%);
}

.section-head {
  max-width: 640px;
  margin-bottom: 40px;
}

.section-sub {
  color: var(--text-muted);
  font-size: 1.05rem;
}

.kicker {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 12px;
}

.lede {
  max-width: 640px;
  font-size: 1.1rem;
  color: var(--text-muted);
  line-height: 1.7;
}

.microcopy {
  font-size: 0.85rem;
  color: var(--text-light);
}

.muted {
  color: var(--text-muted);
}

.prose {
  max-width: 720px;
}

.prose h2 {
  margin-top: 40px;
  color: var(--text);
}

/* ============================================
   CARDS & GRIDS
   ============================================ */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all 0.2s ease;
}

.card:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.card h3 {
  color: var(--text);
  margin-bottom: 12px;
}

.card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.card .meta {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 16px;
}

.two-col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.panel {
  padding: 28px;
  border-radius: var(--radius-lg);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  transition: all 0.2s ease;
}

.panel:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow);
}

.service-detail {
  margin-bottom: 56px;
  padding-bottom: 56px;
  border-bottom: 1px solid var(--border-light);
}

.service-detail:last-child {
  border-bottom: none;
}

.mini-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.mini-card {
  background: var(--bg-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 20px;
}

.mini-card h4 {
  font-size: 0.9rem;
  margin-bottom: 8px;
  color: var(--text);
  font-weight: 600;
}

.mini-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0;
}

/* ============================================
   CTA SECTIONS
   ============================================ */
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.cta-band {
  background: linear-gradient(180deg, var(--bg-subtle) 0%, var(--bg) 100%);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 64px 0;
}

.cta-band-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  align-items: center;
  justify-content: space-between;
}

.cta-band-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  border-top: 1px solid var(--border);
  padding-top: 48px;
  padding-bottom: 32px;
  background: var(--bg-subtle);
  margin-top: 64px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 32px;
  margin-bottom: 32px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}

.footer-note {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer-title {
  font-size: 0.9rem;
  margin-bottom: 12px;
  font-weight: 600;
  color: var(--text);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 8px;
}

.footer-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.9rem;
}

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

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border-light);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--text-light);
}

.footer-credit {
  font-size: 0.85rem;
}

.footer-credit a {
  color: var(--primary);
  text-decoration: none;
}

.footer-credit a:hover {
  text-decoration: underline;
}

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
}

.contact-card {
  background: var(--surface-raised);
}

.copybox {
  position: relative;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-top: 16px;
}

.copybox pre {
  margin: 0;
  white-space: pre-wrap;
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.copybox .btn-small {
  position: absolute;
  top: 12px;
  right: 12px;
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */
.text-link {
  text-decoration: none;
  color: var(--primary);
  font-weight: 500;
}

.text-link:hover {
  text-decoration: underline;
  color: var(--primary-dark);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
  }

  .nav-menu {
    display: none;
    position: absolute;
    right: 0;
    top: 64px;
    flex-direction: column;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: var(--shadow-lg);
    min-width: 200px;
  }

  .nav-menu a {
    width: 100%;
    text-align: left;
  }

  .nav-menu[data-open="true"] {
    display: flex;
  }

  .section {
    padding: 48px 0;
  }

  .page-hero {
    padding-top: 56px;
    padding-bottom: 32px;
  }
}

@media (max-width: 600px) {
  body {
    font-size: 14px;
  }

  h1 {
    font-size: 1.75rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  .card {
    padding: 20px;
  }

  .panel {
    padding: 20px;
  }
}

/* ============================================
   ACCESSIBILITY - REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ============================================
   FLOATING CONTACT CTAs
   ============================================ */
.floating-cta {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.floating-btn {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
  text-decoration: none;
  position: relative;
}

.floating-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.floating-btn:active {
  transform: scale(1.05);
}

/* SMS button - Green */
.floating-sms {
  background: #25D366;
  color: white;
}

.floating-sms:hover {
  background: #1da851;
}

/* Email button - Blue */
.floating-email {
  background: var(--primary);
  color: white;
}

.floating-email:hover {
  background: var(--primary-dark);
}

/* Tooltip on hover */
.floating-btn::before {
  content: attr(title);
  position: absolute;
  right: 100%;
  margin-right: 1rem;
  background: rgba(0, 0, 0, 0.9);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-size: 0.875rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.floating-btn:hover::before {
  opacity: 1;
}

/* Hide tooltips on mobile */
@media (max-width: 768px) {
  .floating-btn::before {
    display: none;
  }
  
  .floating-cta {
    bottom: 1rem;
    right: 1rem;
    gap: 0.75rem;
  }
  
  .floating-btn {
    width: 50px;
    height: 50px;
  }
}

/* Print: hide floating buttons */
@media print {
  .floating-cta {
    display: none;
  }
}

/* Accessibility: reduce motion */
@media (prefers-reduced-motion: reduce) {
  .floating-btn {
    transition: none;
  }
  
  .floating-btn:hover {
    transform: none;
  }
}

/* ============================================
   WORK PREVIEW CAROUSEL
   ============================================ */
.work-preview {
  background: var(--bg-subtle);
}

.carousel-container {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 12px;
}

.carousel-track {
  display: flex;
  transition: transform 0.5s ease;
  will-change: transform;
}

.carousel-item {
  flex: 0 0 100%;
  text-decoration: none;
  color: inherit;
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: var(--surface);
  transition: transform 0.3s ease;
}

.carousel-item:hover {
  transform: scale(0.98);
}

.carousel-image {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  overflow: hidden;
  background: var(--bg-subtle);
}

.carousel-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12px 12px 0 0;
}

.carousel-caption {
  padding: 1.5rem;
  background: var(--surface);
  border-radius: 0 0 12px 12px;
}

.carousel-caption h3 {
  font-size: 1.25rem;
  margin: 0 0 0.5rem 0;
  color: var(--text);
}

.carousel-caption p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0 0 0.75rem 0;
}

.carousel-tag {
  display: inline-block;
  font-size: 0.75rem;
  color: var(--primary);
  background: var(--primary-pale);
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-weight: 500;
}

/* Carousel Buttons */
.carousel-btn {
  position: absolute;
  top: 40%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid var(--border);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  color: var(--text);
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.carousel-btn:hover {
  background: white;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  transform: translateY(-50%) scale(1.1);
}

.carousel-btn-prev {
  left: 1rem;
}

.carousel-btn-next {
  right: 1rem;
}

/* Carousel Indicators */
.carousel-indicators {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 1.5rem;
}

.carousel-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--border);
  cursor: pointer;
  padding: 0;
  transition: all 0.3s ease;
}

.carousel-indicator.active {
  background: var(--primary);
  width: 24px;
  border-radius: 999px;
}

.carousel-indicator:hover {
  background: var(--primary-light);
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .carousel-btn {
    width: 32px;
    height: 32px;
  }
  
  .carousel-btn-prev {
    left: 0.5rem;
  }
  
  .carousel-btn-next {
    right: 0.5rem;
  }
  
  .carousel-caption {
    padding: 1rem;
  }
  
  .carousel-caption h3 {
    font-size: 1.1rem;
  }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
  .site-header,
  .site-footer,
  .nav-menu,
  .cta-band,
  .btn {
    display: none;
  }
  
  body {
    background: white;
    color: black;
  }
}
