/* Aldera Solutions LLC — site styles */

:root {
  --blue-100: #e8f1ff;
  --blue-300: #6fb1ff;
  --blue-500: #1670f5;
  --blue-600: #0b4fc7;
  --navy-800: #0b3d5c;
  --navy-900: #102a43;
  --gray-50: #f7f9fb;
  --gray-100: #eef1f5;
  --gray-200: #dde3ea;
  --gray-500: #5b6b7c;
  --gray-700: #33414f;
  --gray-900: #1a2530;
  --white: #ffffff;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow: 0 4px 16px rgba(16, 42, 67, 0.08);
  --shadow-lg: 0 12px 32px rgba(16, 42, 67, 0.14);
  --max-width: 1140px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* Theme-sensitive tokens: these are the only ones dark mode overrides.
     --white/--navy-800/--navy-900 stay constant (they're also used as
     permanently-dark surfaces like the hero and footer), so text/surface
     uses that need to flip are routed through these instead. */
  --surface: var(--white);
  --heading: var(--navy-900);
  --text-accent: var(--navy-800);
  --link: var(--blue-600);
  --header-bg: rgba(255, 255, 255, 0.92);
  color-scheme: light;
}

:root[data-theme="dark"] {
  --surface: #111b25;
  --gray-50: #0a1218;
  --gray-100: #223140;
  --gray-200: #2c3f4f;
  --gray-500: #93a5b6;
  --gray-700: #cdd8e3;
  --gray-900: #f0f5fa;
  --blue-100: rgba(22, 112, 245, 0.16);
  --heading: #f3f7fb;
  --text-accent: #cfe0f5;
  --link: var(--blue-300);
  --header-bg: rgba(9, 14, 20, 0.82);
  --shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 14px 34px rgba(0, 0, 0, 0.5);
  color-scheme: dark;
}

:root[data-theme="dark"] body { background: var(--surface); }

:root[data-theme="dark"] #form-status.error { background: rgba(220, 38, 38, 0.16); color: #fca5a5; }
:root[data-theme="dark"] #form-status.success { color: var(--blue-300); }

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--gray-700);
  background: var(--surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  color: var(--heading);
  line-height: 1.2;
  margin: 0 0 0.5em;
  font-weight: 700;
}

h1 { font-size: clamp(2rem, 4vw, 2.85rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

section { padding: 64px 0; }
section.tight { padding: 40px 0; }

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--link);
  margin-bottom: 10px;
}

.lede {
  font-size: 1.15rem;
  color: var(--gray-500);
  max-width: 640px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.98rem;
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, color 0.15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn-primary {
  background: var(--blue-500);
  color: var(--white);
  box-shadow: var(--shadow);
}
.btn-primary:hover { background: var(--blue-600); box-shadow: var(--shadow-lg); }

.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.55);
}
.btn-outline:hover { background: rgba(255, 255, 255, 0.12); }

.btn-outline-dark {
  background: transparent;
  color: var(--text-accent);
  border-color: var(--gray-200);
}
.btn-outline-dark:hover { border-color: var(--blue-500); color: var(--link); background: var(--blue-100); }

.btn-block { width: 100%; justify-content: center; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--header-bg);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--gray-100);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--heading);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
}
.brand:hover { text-decoration: none; }
.brand img { width: 40px; height: 40px; }

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

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-links a {
  color: var(--gray-700);
  font-weight: 600;
  font-size: 0.96rem;
}
.nav-links a.active,
.nav-links a:hover { color: var(--link); text-decoration: none; }

.nav-cta { display: flex; align-items: center; gap: 14px; }

.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid var(--gray-200);
  background: transparent;
  color: var(--text-accent);
  cursor: pointer;
  flex-shrink: 0;
  padding: 0;
}
.theme-toggle:hover { border-color: var(--blue-500); color: var(--link); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
.nav-phone {
  font-weight: 700;
  color: var(--text-accent);
  font-size: 0.95rem;
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--heading);
  margin: 5px 0;
  transition: 0.2s;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(150deg, var(--navy-900) 0%, var(--navy-800) 55%, var(--blue-600) 130%);
  color: var(--white);
  padding: 88px 0 76px;
}
.hero .container { position: relative; z-index: 1; }
.hero .eyebrow,
.page-hero .eyebrow { color: var(--blue-300); }
.hero h1 { color: var(--white); max-width: 760px; }
.hero p.lede { color: rgba(255, 255, 255, 0.82); max-width: 620px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }

/* Right-side hero visual: fades in from the solid blue background, stays
   fully contained within the hero section (never bleeds into the next one). */
.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: linear-gradient(90deg, var(--navy-900) 0%, rgba(11, 42, 67, 0.6) 62%, rgba(11, 42, 67, 0.1) 100%),
    url("/assets/server.jpg");
  background-size: cover, cover;
  background-position: center, center right;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, transparent 58%, black 86%);
  mask-image: linear-gradient(90deg, transparent 0%, transparent 58%, black 86%);
}

@media (max-width: 980px) {
  .hero-media { display: none; }
}

.hero-trust {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.78);
}
.hero-trust span { display: flex; align-items: center; gap: 8px; min-width: 0; }
.hero-trust span::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--blue-300);
  flex-shrink: 0;
}

/* Page header (non-home) */
.page-hero {
  background: linear-gradient(150deg, var(--navy-900), var(--navy-800));
  color: var(--white);
  padding: 64px 0 52px;
}
.page-hero h1 { color: var(--white); }
.page-hero p.lede { color: rgba(255, 255, 255, 0.82); }

/* Grid / cards */
.grid {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(3, 1fr);
}
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--gray-100);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow);
}

.icon-badge {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--blue-100);
  color: var(--link);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  flex-shrink: 0;
}
.icon-badge svg { width: 24px; height: 24px; }

.service-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--blue-100);
}
.service-points {
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.service-points li {
  position: relative;
  padding-left: 20px;
  font-size: 0.86rem;
  color: var(--gray-500);
}
.service-points li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.55em;
  width: 6px;
  height: 6px;
  border-radius: 2px;
  background: var(--link);
  opacity: 0.7;
}

.section-head { max-width: 680px; margin-bottom: 40px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

.bg-tint { background: var(--gray-50); }
.bg-navy { background: var(--navy-900); color: var(--white); }
.bg-navy h2, .bg-navy h3 { color: var(--white); }

/* CTA band */
.cta-band {
  background: linear-gradient(120deg, var(--navy-900), var(--blue-600) 60%, var(--blue-500));
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.cta-band > div { min-width: 0; }
.cta-band h2 { color: var(--white); margin-bottom: 6px; }
.cta-band p { color: rgba(255, 255, 255, 0.9); margin: 0; }

/* FAQ accordion */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 820px;
}
.faq-list details {
  background: var(--surface);
  border: 1px solid var(--gray-100);
  border-radius: var(--radius);
  padding: 4px 22px;
  transition: border-color 0.15s ease;
}
.faq-list details[open] { border-color: var(--blue-100); }
.faq-list summary {
  padding: 16px 0;
  font-weight: 600;
  color: var(--heading);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: "+";
  flex-shrink: 0;
  font-size: 1.3rem;
  line-height: 1;
  color: var(--link);
}
.faq-list details[open] summary::after { content: "\2212"; }
.faq-list details p {
  margin: 0 0 18px;
  color: var(--gray-500);
}

/* Service area list */
.area-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  padding: 0;
  list-style: none;
}
.area-list li {
  background: var(--surface);
  border: 1px solid var(--gray-200);
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-accent);
}
.area-list li.primary {
  background: var(--navy-900);
  border-color: var(--navy-900);
  color: var(--white);
}

/* Contact page */
.contact-wrap {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 40px;
  align-items: start;
}

.contact-card {
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  padding: 32px;
  border: 1px solid var(--gray-100);
}
.contact-card h3 { margin-top: 24px; }
.contact-card h3:first-child { margin-top: 0; }
.contact-line { display: flex; gap: 12px; margin-bottom: 14px; align-items: flex-start; }
.contact-line .icon-badge { margin-bottom: 0; width: 36px; height: 36px; border-radius: 9px; }
.contact-line div a { color: var(--text-accent); font-weight: 600; }

.hours-list { list-style: none; padding: 0; margin: 0; }
.hours-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  border-bottom: 1px solid var(--gray-100);
  font-size: 0.92rem;
}
.hours-list li:last-child { border-bottom: none; }
.hours-list li span:first-child { color: var(--text-accent); font-weight: 600; }
.hours-list li span:last-child { color: var(--gray-500); }

form.card { padding: 32px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-accent);
  margin-bottom: 6px;
}
.field .hint { font-weight: 400; color: var(--gray-500); font-size: 0.82rem; }
.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field select,
.field textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  font-size: 0.96rem;
  font-family: inherit;
  color: var(--gray-900);
  background: var(--surface);
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px var(--blue-100);
}
.field textarea { resize: vertical; min-height: 120px; }

.consent-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: 400;
  font-size: 0.88rem;
  color: var(--gray-700);
  cursor: pointer;
}
.consent-label input {
  accent-color: var(--blue-500);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: 3px;
}

/* honeypot field, hidden from real users */
.hp-field {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-note {
  font-size: 0.82rem;
  color: var(--gray-500);
  margin-top: 6px;
}

#form-status {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.92rem;
  display: none;
}
#form-status.show { display: block; }
#form-status.success { background: var(--blue-100); color: var(--blue-600); }
#form-status.error { background: #fdecec; color: #9c2b2b; }

/* Footer */
.site-footer {
  background: var(--navy-900);
  color: rgba(255, 255, 255, 0.75);
  padding: 48px 0 28px;
  font-size: 0.92rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}
.footer-brand { display: flex; align-items: center; gap: 10px; color: var(--white); font-weight: 800; font-size: 1.1rem; margin-bottom: 12px; }
.footer-brand img { width: 38px; height: 38px; }
.site-footer h4 { color: var(--white); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 14px; }
.site-footer a { color: rgba(255, 255, 255, 0.75); }
.site-footer a:hover { color: var(--white); }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 10px; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.55);
}
.footer-bottom span { min-width: 0; }

/* Policy page */
.policy h2 { margin-top: 2em; }
.policy ul { padding-left: 1.2em; }
.policy hr { border: none; border-top: 1px solid var(--gray-200); margin: 2em 0; }

/* Blog */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.post-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--gray-100);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.post-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--blue-500);
}

/* The title link's ::after is stretched over the whole card so the card
   is clickable anywhere; .post-tags sits above it (z-index) so tag pills
   stay independently clickable for filtering. */
.post-card-link::after { content: ""; position: absolute; inset: 0; z-index: 1; }

.post-card-media,
.post-hero-media {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--navy-900), var(--blue-600));
}
.post-card-media { display: block; aspect-ratio: 16 / 10; }
.post-hero-media {
  height: 380px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  margin: 24px 0 40px;
}
.post-card-media img,
.post-hero-media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.35s ease; }
.post-card:hover .post-card-media img { transform: scale(1.06); }
.post-card-media.no-image::after,
.post-hero-media.no-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("/assets/logo-header.png");
  background-repeat: no-repeat;
  background-position: center;
  opacity: 0.55;
}
.post-card-media.no-image::after { background-size: 56px 56px; }
.post-hero-media.no-image::after { background-size: 96px 96px; }

.post-card-body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.post-category {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
}
.post-card-body .post-category { align-self: flex-start; }
.post-card-body h3 { font-size: 1.02rem; line-height: 1.35; margin-bottom: 6px; }
.post-card-body h3 a { color: var(--heading); }
.post-card-body h3 a:hover { color: var(--link); text-decoration: none; }
.post-summary { color: var(--gray-500); font-size: 0.87rem; flex: 1; margin-bottom: 12px; }
.post-meta { font-size: 0.78rem; color: var(--gray-500); margin-bottom: 10px; }

.post-tags { position: relative; z-index: 2; display: flex; flex-wrap: wrap; gap: 6px; align-self: flex-start; }
.tag-pill {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}
.tag-pill:hover { text-decoration: none; transform: translateY(-1px); box-shadow: var(--shadow); filter: brightness(0.95); }

.tag-filter-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
  font-size: 0.92rem;
  color: var(--gray-500);
}
.tag-filter-bar strong { color: var(--heading); }

.post-article-wrap { max-width: 760px; margin: 0 auto; }
.post-meta-top {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--gray-500);
  font-size: 0.92rem;
  margin-bottom: 14px;
}
.post-article-wrap h1 { margin-bottom: 16px; }
.post-article-wrap .post-tags { margin-bottom: 8px; }

.post-detail-footer {
  margin-top: 48px;
  padding-top: 28px;
  border-top: 1px solid var(--gray-100);
}

.post-content { font-size: 1.05rem; line-height: 1.75; color: var(--gray-700); padding-bottom: 8px; }
.post-content h2 { margin-top: 1.6em; }
.post-content h3 { margin-top: 1.4em; }
.post-content ul, .post-content ol { padding-left: 1.4em; margin: 0 0 1em; }
.post-content li { margin-bottom: 0.4em; }
.post-content blockquote {
  border-left: 3px solid var(--blue-500);
  margin: 1.5em 0;
  padding: 0.2em 0 0.2em 1.2em;
  color: var(--text-accent);
  font-style: italic;
}
.post-content pre {
  background: var(--gray-50);
  border: 1px solid var(--gray-100);
  border-radius: 8px;
  padding: 16px;
  overflow-x: auto;
  font-size: 0.9rem;
}
.post-content code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.post-content figure { margin: 1.6em 0; }
.post-content figure img { border-radius: var(--radius); }
.post-content figcaption { font-size: 0.85rem; color: var(--gray-500); margin-top: 8px; text-align: center; }
.post-content hr { border: none; border-top: 1px solid var(--gray-200); margin: 2em 0; }
.post-callout {
  display: flex;
  gap: 12px;
  background: var(--gray-50);
  border: 1px solid var(--gray-100);
  border-radius: 10px;
  padding: 16px 18px;
  margin: 1.4em 0;
}
.post-callout-icon { font-size: 1.2rem; }

/* Utility */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; }

@media (max-width: 880px) {
  .nav-menu { display: none; }
  .nav-toggle { display: block; }
  body.nav-open .nav-menu {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--surface);
    padding: 20px 24px 26px;
    border-bottom: 1px solid var(--gray-100);
    box-shadow: var(--shadow-lg);
  }
  body.nav-open .nav-links { flex-direction: column; align-items: flex-start; gap: 14px; }
  body.nav-open .nav-cta { flex-direction: column; align-items: flex-start; gap: 14px; width: 100%; }
  body.nav-open .nav-cta .btn { width: 100%; justify-content: center; }
  .grid, .grid.cols-2, .grid.cols-4, .blog-grid { grid-template-columns: 1fr; }
  .post-hero-media { height: 200px; }
  .contact-wrap { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .cta-band { flex-direction: column; align-items: flex-start; }
  section { padding: 48px 0; }
}
