/* ===================================================
   NORTHBYTE WEB STUDIO — BASE STYLES
   Shared variables, resets, typography, global elements
=================================================== */

/* Root tokens */
:root {
  --nb-navy: #0A1B2E;
  --nb-teal: #008CFF;
  --nb-cloud: #F7F9FB;
  --nb-slate: #1E293B;
  --nb-light: #FFFFFF;
  --radius: 10px;

  --font-body: 'Inter', sans-serif;
  --font-heading: 'Montserrat', sans-serif;

  --max-width: 1200px;
  --section-space: clamp(3rem, 6vw, 6rem);
  --hero-gradient: linear-gradient(135deg, #08172b 0%, #003C8F 100%);
}

/* Reset & base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  padding: 0;
  font-family: var(--font-body);
  color: var(--nb-slate);
  background: var(--nb-light);
  line-height: 1.7;
  font-size: 1rem;
}
img { max-width: 100%; height: auto; display: block; }
.container { width: 90%; max-width: var(--max-width); margin: 0 auto; }

/* Skip to content link (accessibility) */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--nb-teal);
  color: white;
  padding: 0.5rem 1rem;
  text-decoration: none;
  z-index: 100;
  border-radius: 0 0 var(--radius) 0;
  font-weight: 600;
}
.skip-link:focus {
  top: 0;
  outline: 3px solid var(--nb-navy);
  outline-offset: 3px;
}

/* Visually hidden (for screen readers) */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Typography */
h1,h2,h3,h4 {
  font-family: var(--font-heading);
  color: var(--nb-navy);
  line-height: 1.3;
  margin-top: 0;
}
h1 { font-size: clamp(2rem, 4vw, 3.5rem); }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); margin-bottom: 0.5rem; }
h3 { font-size: clamp(1.25rem, 2vw, 1.75rem); }
h4 { font-size: clamp(1.1rem, 1.5vw, 1.5rem); }
p  { margin-bottom: 1.2rem; color: var(--nb-slate); }
a  { color: var(--nb-teal); text-decoration: none; }
a:hover,a:focus { text-decoration: underline; }

/* Enhanced focus indicators (WCAG 2.2 AA) */
:focus-visible {
  outline: 3px solid var(--nb-teal);
  outline-offset: 3px;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--nb-teal);
  outline-offset: 3px;
  box-shadow: 0 0 0 3px rgba(0, 140, 255, 0.2);
}

/* Buttons (shared look with minimum touch targets) */
.btn-primary,
.btn-outline,
.btn-nav {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.9rem 1.6rem;
  border-radius: var(--radius);
  font-weight: 600;
  transition: all 0.3s ease;
  text-decoration: none;
  cursor: pointer;
}
.btn-primary {
  background: #0094FF;
  color: #fff;
  border: none;
  box-shadow: 0 2px 8px rgba(0,148,255,0.15);
}
.btn-primary:hover,
.btn-primary:focus {
  background: #0078e6;
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0,148,255,0.2);
  text-decoration: none;
}
.btn-outline {
  border: 2px solid #fff;
  color: #fff;
  background: transparent;
}
.btn-outline:hover,
.btn-outline:focus {
  background: #fff;
  color: var(--nb-navy);
  text-decoration: none;
}
.btn-large {
  padding: 1.1rem 2rem;
  font-size: 1.1rem;
}

/* Footer & Scroll-to-top baseline */
.footer { background:#08172B; color:#e4eaf0; font-size:.95rem; }
.scroll-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: var(--nb-teal);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 48px;
  height: 48px;
  font-size: 1.4rem;
  cursor: pointer;
  display: none;
  justify-content: center;
  align-items: center;
  box-shadow: 0 3px 10px rgba(0,0,0,0.15);
  transition: all 0.3s;
  z-index: 1000;
}
.scroll-top.show { display: flex; }
.scroll-top:hover,
.scroll-top:focus {
  background: #0078e6;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}
.cursor {
  color: var(--nb-teal);
  font-weight: bold;
  animation: blink 0.9s step-start infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

/* Hero trust badge styling */
.hero-trust {
  display: inline-block;
  background: rgba(255, 255, 255, 0.95);
  color: var(--nb-navy);
  padding: 0.5rem 1rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* Hero stats container enhancement */
.hero-stats {
  display: flex;
  gap: 2rem;
  margin-top: 2rem;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 1.5rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Form error message styling */
.form-group {
  position: relative;
  width: 100%;
}

.error-message {
  display: block;
  color: #dc2626;
  font-size: 0.875rem;
  margin-top: 0.25rem;
  min-height: 1.25rem;
}

.error-message:empty {
  display: none;
}

input.error,
textarea.error,
select.error {
  border-color: #dc2626;
  background-color: #fef2f2;
}

/* Minimum touch targets for navigation */
.nav a,
.contact-method {
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 1rem;
}

/* Reduced motion support (WCAG 2.2) */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  
  .cursor {
    animation: none;
  }
}


/* ===================================================
   SEO SERVICES PAGE
=================================================== */

/* HERO */
.hero-seo {
  background: linear-gradient(135deg, #0a1b2e 0%, #0047b2 100%);
  color: #fff;
  padding: 7rem 1rem;
}
.hero-seo .hero-heading { margin-bottom: 1rem; }
.hero-seo .hero-subtext { max-width: 720px; color: #e0e8f5; }

/* OVERVIEW */
.overview {
  background: var(--nb-cloud);
  padding: var(--section-space) 1rem;
  text-align: center;
}
.overview p {
  max-width: 800px;
  margin: 0 auto;
  color: var(--nb-slate);
}

/* FEATURES */
.features-section {
  background: #fff;
  padding: var(--section-space) 1rem;
  text-align: center;
}
.features-section .grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.features-section .card {
  background: var(--nb-cloud);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: 0 5px 15px rgba(11, 30, 63, 0.05);
  transition: transform 0.3s ease;
}
.features-section .card:hover {
  transform: translateY(-6px);
}

/* PROCESS */
.process {
  background: var(--nb-cloud);
  padding: var(--section-space) 1rem;
  text-align: center;
}
.process .grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

/* FAQ */
.faq {
  background: #fff;
  padding: var(--section-space) 1rem;
}
.faq details {
  margin-bottom: 1rem;
  border: 1px solid #ddd;
  border-radius: var(--radius);
  padding: 1rem 1.2rem;
  background: var(--nb-cloud);
}
.faq summary {
  font-weight: 600;
  cursor: pointer;
  color: var(--nb-navy);
}
.faq p { margin-top: 0.8rem; }

/* CTA */
.cta-section {
  background: var(--nb-navy);
  color: #fff;
  text-align: center;
  padding: var(--section-space) 1rem;
}
.cta-section .btn-primary {
  background: var(--nb-teal);
  color: var(--nb-navy);
}

/* ===================================================
   PORTFOLIO PAGE
=================================================== */

/* Portfolio Hero */
.page-hero {
  background: linear-gradient(135deg, #0a1b2e 0%, #0047b2 100%);
  color: #fff;
  padding: 5rem 1rem 4rem;
  text-align: center;
}

.breadcrumb {
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  opacity: 0.9;
}

.breadcrumb a {
  color: #fff;
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.hero-subtitle {
  max-width: 700px;
  margin: 1rem auto 2.5rem;
  font-size: 1.15rem;
  color: #e0e8f5;
}

.portfolio-stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-top: 3rem;
  flex-wrap: wrap;
}

.portfolio-stats .stat {
  text-align: center;
}

.portfolio-stats .stat strong {
  display: block;
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--nb-teal);
  margin-bottom: 0.25rem;
}

.portfolio-stats .stat span {
  font-size: 0.95rem;
  color: #e0e8f5;
}

/* Portfolio Section */
.portfolio-section {
  padding: var(--section-space) 1rem;
  background: #fff;
}

.portfolio-item {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  margin-bottom: 5rem;
  padding-bottom: 5rem;
  border-bottom: 1px solid #e5e7eb;
}

.portfolio-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.portfolio-item.reverse {
  direction: rtl;
}

.portfolio-item.reverse > * {
  direction: ltr;
}

.portfolio-image {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.portfolio-image:hover {
  transform: scale(1.02);
}

.portfolio-image img {
  width: 100%;
  height: auto;
  display: block;
}

.portfolio-content h2 {
  color: var(--nb-navy);
  margin-bottom: 0.5rem;
}

.portfolio-category {
  color: var(--nb-teal);
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

.portfolio-description {
  color: var(--nb-slate);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.portfolio-features {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}

.portfolio-features li {
  padding: 0.5rem 0;
  color: var(--nb-slate);
  font-size: 0.95rem;
}

.portfolio-results {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.result-badge {
  background: var(--nb-cloud);
  color: var(--nb-navy);
  padding: 0.5rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid #e5e7eb;
}

/* CTA Buttons */
.cta-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 2rem;
  flex-wrap: wrap;
}
