/* ==========================================================================
   Virtual Solutionz - Clean Professional White Theme
   Compatible with Cloudflare Pages & Static Workers
   ========================================================================== */

:root {
  --bg-dark: #ffffff;
  --bg-card: #f8fafc;
  --bg-card-hover: #f1f5f9;
  --border-color: #e2e8f0;
  --border-glow: rgba(0, 112, 243, 0.2);
  
  --primary: #0070f3;
  --primary-glow: #3291ff;
  --accent-purple: #7928ca;
  --accent-pink: #ff0080;
  --accent-green: #10b981;
  --accent-gold: #f59e0b;

  --text-main: #334155;
  --text-muted: #64748b;
  --text-heading: #0f172a;

  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Space Grotesk', sans-serif;

  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
}

/* Reset & Global Elements */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 90px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* prevents accidental horizontal scroll on iOS */
  max-width: 100%;
}

/* Locks background scrolling while the mobile drawer is open */
body.nav-open {
  overflow: hidden;
  touch-action: none;
}

/* Anchor targets clear the fixed header */
section[id] {
  scroll-margin-top: 90px;
}

img, svg, video, canvas {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

ul {
  list-style: none;
}

.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
}

/* Typography & Utilities */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--text-heading);
  line-height: 1.2;
}

.gradient-text {
  background: linear-gradient(135deg, var(--primary) 0%, #00a6ff 50%, var(--accent-purple) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section-tag {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--primary);
  margin-bottom: 0.75rem;
  background: rgba(0, 112, 243, 0.08);
  padding: 4px 14px;
  border-radius: 20px;
  border: 1px solid rgba(0, 112, 243, 0.15);
}

.section-title {
  font-size: clamp(1.65rem, 1.15rem + 2.1vw, 2.4rem);
  margin-bottom: 1rem;
  text-wrap: balance;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: clamp(1rem, 0.95rem + 0.2vw, 1.1rem);
  max-width: 650px;
  margin: 0 auto;
}

.text-center { text-align: center; }
.text-gold { color: var(--accent-gold); }
.text-purple { color: var(--accent-purple); }
.text-cyan { color: var(--primary); }
.text-green { color: var(--accent-green); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.8rem 1.6rem;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: var(--transition);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-glow));
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 4px 20px rgba(0, 112, 243, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(0, 112, 243, 0.35);
  background: linear-gradient(135deg, #005bb5, var(--primary));
}

.btn-outline {
  background: #ffffff;
  color: var(--text-heading);
  border: 1px solid var(--border-color);
  box-shadow: 0 2px 5px rgba(0,0,0,0.03);
}

.btn-outline:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  transform: translateY(-2px);
}

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

.btn-block {
  width: 100%;
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1.2rem 0;
  transition: var(--transition);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
}

.navbar.scrolled {
  padding: 0.8rem 0;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid var(--border-color);
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Brand logo: local icon + wordmark (the old WordPress asset is no longer online) */
.logo-container {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.site-logo-img {
  height: 42px;
  width: 42px;
  object-fit: contain;
  display: block;
  flex: 0 0 auto;
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-heading);
  white-space: nowrap;
}

.brand-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.footer .logo-text {
  color: #ffffff;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
}

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

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

/* Hero Section */
.hero {
  position: relative;
  padding: 10rem 0 6rem;
  overflow: hidden;
  background: radial-gradient(circle at top center, rgba(0, 112, 243, 0.04) 0%, rgba(255, 255, 255, 0) 70%);
}

.hero-bg-glow {
  position: absolute;
  top: -150px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 500px;
  background: radial-gradient(circle, rgba(0, 112, 243, 0.08) 0%, rgba(121, 40, 202, 0.04) 40%, rgba(255, 255, 255, 0) 70%);
  filter: blur(80px);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #f1f5f9;
  border: 1px solid var(--border-color);
  padding: 0.4rem 1rem;
  border-radius: 30px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: var(--text-heading);
}

.hero-title {
  font-size: clamp(2rem, 1.35rem + 3.1vw, 3.4rem);
  margin-bottom: 1.2rem;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 540px;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  margin-bottom: 3rem;
}

.hero-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.metric-item {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.metric-num {
  font-family: var(--font-heading);
  font-size: clamp(1.35rem, 1.1rem + 0.9vw, 1.8rem);
  font-weight: 700;
  color: var(--primary);
}

.metric-label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Hero Visual / Code Card */
.hero-visual {
  position: relative;
}

.glass-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.06);
}

.card-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 1.2rem;
  background: #f8fafc;
  border-bottom: 1px solid var(--border-color);
}

.dots {
  display: flex;
  gap: 6px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot.red { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green { background: #27c93f; }

.bar-title {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: monospace;
}

.code-preview {
  padding: 1.25rem;
  font-family: 'Consolas', 'Fira Code', monospace;
  font-size: clamp(0.7rem, 0.6rem + 0.45vw, 0.9rem);
  line-height: 1.6;
  background: #ffffff;
  color: #1e293b;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.code-preview pre {
  margin: 0;
  min-width: max-content;
}

.code-preview .kwd { color: #d73a49; }
.code-preview .var { color: #005cc5; }
.code-preview .prop { color: #6f42c1; }
.code-preview .str { color: #032f62; }
.code-preview .num { color: #005cc5; }
.code-preview .func { color: #6f42c1; }

.status-indicator {
  padding: 0.8rem 1.2rem;
  background: #f0fdf4;
  border-top: 1px solid #dcfce7;
  font-size: 0.8rem;
  color: #166534;
  display: flex;
  align-items: center;
  gap: 8px;
}

.status-dot {
  width: 8px;
  height: 8px;
  background-color: var(--accent-green);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent-green);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.2); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

.floating-badge {
  position: absolute;
  background: #ffffff;
  border: 1px solid var(--border-color);
  padding: 0.8rem 1.2rem;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.floating-badge i { font-size: 1.4rem; }
.floating-badge strong { display: block; font-size: 0.9rem; color: var(--text-heading); }
.floating-badge small { color: var(--text-muted); font-size: 0.75rem; }

.fb-1 { top: -26px; right: -26px; }
.fb-2 { bottom: -26px; left: -26px; }

/* Services Section */
.services {
  padding: 6rem 0;
  background: #fafafa;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: 2rem;
  margin-top: 3.5rem;
}

.service-card {
  position: relative;
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  transition: var(--transition);
  box-shadow: 0 4px 20px rgba(0,0,0,0.03);
}

.service-card:hover {
  transform: translateY(-6px);
  border-color: rgba(0, 112, 243, 0.4);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08);
}

.service-card.highlighted {
  border-color: var(--primary);
  background: linear-gradient(180deg, rgba(0, 112, 243, 0.03) 0%, #ffffff 100%);
}

.service-tag {
  position: absolute;
  top: 1.2rem;
  right: 1.2rem;
  background: var(--primary);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 12px;
  text-transform: uppercase;
}

.service-icon {
  width: 55px;
  height: 55px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}

.bg-purple { background: rgba(121, 40, 202, 0.1); color: #7928ca; }
.bg-blue { background: rgba(0, 112, 243, 0.1); color: var(--primary); }
.bg-green { background: rgba(16, 185, 129, 0.1); color: var(--accent-green); }

.service-card h3 {
  font-size: 1.4rem;
  margin-bottom: 0.8rem;
}

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

.service-features li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--text-main);
  margin-bottom: 0.5rem;
}

.service-features i {
  color: var(--primary);
  font-size: 0.8rem;
}

/* Estimator / Calculator Section */
.calculator-section {
  padding: 4rem 0 6rem;
}

.glass-container {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 3.5rem 2.5rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.04);
}

.calc-body {
  max-width: 800px;
  margin: 2.5rem auto 0;
}

.calc-group {
  margin-bottom: 2rem;
}

.calc-label {
  display: block;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-heading);
}

.calc-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}

.calc-btn {
  background: #f8fafc;
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 1rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  font-weight: 600;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}

.calc-btn i { font-size: 1.3rem; }

.calc-btn.active, .calc-btn:hover {
  border-color: var(--primary);
  background: rgba(0, 112, 243, 0.06);
  color: var(--text-heading);
}

.calc-checkboxes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.check-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f8fafc;
  border: 1px solid var(--border-color);
  padding: 0.9rem 1.2rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
}

.check-card input { display: none; }

.check-box {
  width: 18px;
  height: 18px;
  border: 2px solid var(--text-muted);
  border-radius: 4px;
  display: inline-block;
  position: relative;
  transition: var(--transition);
}

.check-card input:checked + .check-box {
  background-color: var(--primary);
  border-color: var(--primary);
}

.check-card input:checked + .check-box::after {
  content: '✓';
  position: absolute;
  top: -3px;
  left: 3px;
  color: #fff;
  font-size: 12px;
  font-weight: bold;
}

.calc-result-box {
  margin-top: 2.5rem;
  background: #f8fafc;
  border: 1px solid var(--border-color);
  padding: 1.8rem 2rem;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.price-tag {
  font-size: clamp(1.9rem, 1.4rem + 2vw, 2.5rem);
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--primary);
  line-height: 1.1;
}

/* About Us */
.about {
  padding: 6rem 0;
  background: #fafafa;
}

.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3.5rem;
  align-items: center;
}

.about-text {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 2rem;
}

.skills-progress {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.skill-info {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}

.progress-bar {
  height: 8px;
  background: #e2e8f0;
  border-radius: 10px;
  overflow: hidden;
}

.progress {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent-purple));
  border-radius: 10px;
}

.about-cards-column {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.info-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  padding: 1.5rem 1.8rem;
  border-radius: var(--radius-md);
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.info-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 8px 25px rgba(0,0,0,0.06);
}

.info-card i {
  font-size: 1.5rem;
  margin-bottom: 0.6rem;
}

.info-card h4 {
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
}

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

/* Portfolio Section */
.portfolio {
  padding: 6rem 0;
}

.portfolio-filter {
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  margin: 2.5rem 0 3rem;
  flex-wrap: wrap;
}

.filter-btn {
  background: #f1f5f9;
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 0.5rem 1.2rem;
  border-radius: 20px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
}

.filter-btn.active, .filter-btn:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  font-weight: 700;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr));
  gap: 1.8rem;
}

.portfolio-item {
  transition: var(--transition);
}

.item-inner {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: var(--transition);
  box-shadow: 0 4px 20px rgba(0,0,0,0.03);
}

.portfolio-item:hover .item-inner {
  transform: translateY(-5px);
  border-color: var(--primary);
  box-shadow: 0 10px 30px rgba(0, 112, 243, 0.12);
}

.item-badge {
  font-size: 0.75rem;
  color: var(--primary);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 0.8rem;
}

.item-icon {
  font-size: 2rem;
  color: var(--text-heading);
  margin-bottom: 1rem;
}

.item-inner h3 {
  font-size: 1.3rem;
  margin-bottom: 0.6rem;
}

.item-inner p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tags span {
  background: #f1f5f9;
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 6px;
  color: var(--text-muted);
}

/* Testimonials */
.testimonials {
  padding: 6rem 0;
  background: #fafafa;
}

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.testimonial-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  padding: 2.2rem;
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 4px 20px rgba(0,0,0,0.03);
}

.testimonial-card.highlighted-test {
  border-color: rgba(121, 40, 202, 0.3);
  background: linear-gradient(180deg, rgba(121, 40, 202, 0.03) 0%, #ffffff 100%);
}

.stars {
  color: var(--accent-gold);
  letter-spacing: 2px;
  margin-bottom: 1rem;
}

.quote {
  font-style: italic;
  font-size: 0.98rem;
  color: var(--text-main);
  margin-bottom: 1.5rem;
}

.author-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar-ph {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent-purple));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: #fff;
}

.author-info strong {
  display: block;
  font-size: 0.95rem;
}

.author-info span {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Contact Section */
.contact {
  padding: 6rem 0 8rem;
}

.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3.5rem;
  align-items: start;
}

.contact-info p {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-top: 1rem;
  margin-bottom: 2.5rem;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.c-detail {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.c-detail i {
  font-size: 1.4rem;
  width: 45px;
  height: 45px;
  background: #f8fafc;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
}

.c-detail strong { display: block; font-size: 0.95rem; }
.c-detail span { color: var(--text-muted); font-size: 0.85rem; }

.contact-form-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 40px rgba(0,0,0,0.06);
}

.contact-form-card h3 {
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
}

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

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--text-heading);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  min-height: 48px;
  padding: 0.8rem 1rem;
  background: #f8fafc;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-heading);
  font-family: inherit;
  /* 16px keeps iOS Safari from zooming on focus */
  font-size: 1rem;
  line-height: 1.5;
  transition: var(--transition);
  -webkit-appearance: none;
  appearance: none;
}

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

.form-group select option {
  background: #ffffff;
  color: #1e293b;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 10px rgba(0, 112, 243, 0.15);
  background: #ffffff;
}

.form-status {
  margin-top: 1rem;
  font-size: 0.9rem;
  padding: 0.8rem;
  border-radius: var(--radius-sm);
  display: none;
}

.form-status.success {
  display: block;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #047857;
}

.form-status.error {
  display: block;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #b91c1c;
}

/* Footer */
.footer {
  background: #0f172a;
  color: #f1f5f9;
  border-top: 1px solid #1e293b;
  padding: 4rem 0 2rem;
}

.footer h4 {
  color: #ffffff;
}

.footer a {
  color: #94a3b8;
}

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

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

.footer-brand p {
  color: #94a3b8;
  font-size: 0.9rem;
  margin-top: 1rem;
  max-width: 320px;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.f-col h4 {
  font-size: 1rem;
  margin-bottom: 1.2rem;
}

.f-col a {
  display: block;
  font-size: 0.88rem;
  margin-bottom: 0.6rem;
}

.hosting-badge {
  display: inline-block;
  font-size: 0.78rem;
  color: #94a3b8;
  margin-bottom: 0.6rem;
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  font-size: 0.85rem;
  color: #94a3b8;
}

/* Brand logo: local icon + wordmark (the old WordPress asset is no longer online) */
.logo-container {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.site-logo-img {
  height: 42px;
  width: 42px;
  object-fit: contain;
  display: block;
  flex: 0 0 auto;
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-heading);
  white-space: nowrap;
}

.brand-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.footer .logo-text {
  color: #ffffff;
}

/* ==========================================================================
   Responsive
   Mobile-first refinements layered on top of the desktop styles above.
   ========================================================================== */

/* ---------- Large tablets / small laptops ---------- */
@media (max-width: 1024px) {
  .services,
  .about,
  .portfolio,
  .testimonials,
  .contact,
  .calculator-section {
    padding-block: clamp(3.25rem, 2.4rem + 2.6vw, 5rem);
  }

  .hero {
    padding-top: clamp(7rem, 6rem + 3vw, 9rem);
    padding-bottom: clamp(3rem, 2.4rem + 2vw, 4.5rem);
  }

  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 2.75rem;
    text-align: center;
  }

  /* Grid children must be allowed to shrink below their content width */
  .hero-content,
  .hero-visual,
  .about-content,
  .about-cards-column,
  .contact-info,
  .contact-form-card,
  .footer-brand,
  .footer-links {
    min-width: 0;
  }

  .hero-subtitle { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-metrics { justify-content: center; }

  /* Floating chips stop floating and join the layout */
  .hero-visual {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
    max-width: 620px;
    margin: 0 auto;
  }

  .hero-visual .main-card { width: 100%; }

  .floating-badge {
    position: static;
    flex: 1 1 220px;
    justify-content: center;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
  }

  .about-grid { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
  .contact-wrapper { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
  .footer-content { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
  .footer-brand p { max-width: none; }
  .glass-container { padding: 2.75rem 2rem; }
  .universe-box { padding: 2.5rem 1.75rem; }
}

/* ---------- Tablets ---------- */
@media (max-width: 900px) {
  .container { padding: 0 1.25rem; }

  /* Keep the header (and its close button) above the full-screen drawer */
  .navbar { z-index: 1000; }

  .mobile-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: #ffffff;
    position: relative;
    z-index: 1002;
    cursor: pointer;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 100dvh;
    padding: 5.5rem 1.5rem 2.5rem;
    background: #ffffff;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0.35rem;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
    z-index: 999;
  }

  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav-link {
    display: flex;
    align-items: center;
    min-height: 52px;
    padding: 0 0.25rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-heading);
    border-bottom: 1px solid var(--border-color);
  }

  .nav-menu .nav-cta {
    margin-top: 1.5rem;
    min-height: 52px;
    font-size: 1rem;
  }

  .hero-actions {
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .footer-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .f-col a {
    display: flex;
    align-items: center;
    min-height: 40px;
    margin-bottom: 0;
  }
}

/* ---------- Phones ---------- */
@media (max-width: 640px) {
  .container { padding: 0 1rem; }

  section[id] { scroll-margin-top: 76px; }

  .navbar { padding: 0.75rem 0; }
  .site-logo-img { height: 34px; width: 34px; }
  .logo-text { font-size: 1rem; }

  .badge {
    font-size: 0.78rem;
    padding: 0.35rem 0.8rem;
  }

  .hero { padding-top: 6.5rem; }
  .hero-subtitle { font-size: 1rem; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }

  .hero-metrics {
    gap: 1rem 1.5rem;
    justify-content: space-around;
    text-align: center;
  }

  .metric-item { flex: 1 1 30%; align-items: center; }
  .metric-label { font-size: 0.75rem; line-height: 1.3; }

  .floating-badge {
    flex: 1 1 100%;
    padding: 0.7rem 1rem;
  }

  .card-header-bar { padding: 0.6rem 0.9rem; }
  .bar-title { display: none; }
  .chat-preview { padding: 1rem; }
  .chat-msg { max-width: 95%; font-size: 0.88rem; }

  .services-grid,
  .portfolio-grid,
  .testimonial-grid { gap: 1.25rem; }

  .service-card,
  .item-inner,
  .testimonial-card,
  .conv-card {
    padding: 1.6rem;
  }

  .glass-container { padding: 2rem 1.15rem; border-radius: var(--radius-md); }

  .calc-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .calc-checkboxes { grid-template-columns: 1fr; }
  .calc-btn { padding: 0.85rem 0.5rem; font-size: 0.85rem; }
  .check-card { padding: 0.85rem 1rem; }

  .calc-result-box {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    padding: 1.5rem 1.15rem;
    gap: 1.15rem;
  }

  .calc-result-box .btn { width: 100%; }

  .portfolio-filter {
    justify-content: flex-start;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 0.5rem;
    margin-inline: -1rem;
    padding-inline: 1rem;
  }

  .portfolio-filter::-webkit-scrollbar { display: none; }

  .filter-btn {
    flex: 0 0 auto;
    min-height: 44px;
    padding: 0.55rem 1.1rem;
  }

  .contact-form-card { padding: 1.6rem 1.15rem; }
  .contact-details { gap: 1.15rem; }
  .c-detail { align-items: flex-start; }
  .c-detail span { overflow-wrap: anywhere; }

  .footer { padding: 3rem 0 1.5rem; }
  .footer-links { grid-template-columns: 1fr; gap: 1.75rem; }
  .f-col a { min-height: 40px; display: flex; align-items: center; }
  .f-col a { margin-bottom: 0; }
}

/* ---------- Small phones ---------- */
@media (max-width: 380px) {
  .container { padding: 0 0.85rem; }
  .calc-options { grid-template-columns: 1fr; }
  .hero-metrics { flex-direction: column; align-items: stretch; gap: 0.9rem; }
  .metric-item { flex-direction: row; align-items: baseline; gap: 0.5rem; }
}

/* ---------- Short landscape (phone on its side) ---------- */
@media (max-height: 520px) and (orientation: landscape) {
  .nav-menu {
    height: 100dvh;
    padding-top: 4.5rem;
    overflow-y: auto;
  }
  .hero { padding-top: 5.5rem; }
}

/* ---------- Touch devices: no hover-lift jitter ---------- */
@media (hover: none) {
  .service-card:hover,
  .portfolio-item:hover .item-inner,
  .info-card:hover,
  .btn-primary:hover,
  .btn-outline:hover {
    transform: none;
  }
}

/* ---------- Respect reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

