/* Sentinel Valley Smart Homes - Cyber-Glass Theme */

:root {
    --cyan-glow: #38bdf8;
    --neon-blue: #0284c7;
    --glass-bg: rgba(15, 23, 42, 0.72);
    --glass-border: rgba(56, 189, 248, 0.28);
    --glass-border-hover: rgba(56, 189, 248, 0.85);
    --text-primary: #f8fafc;
    --text-muted: #94a3b8;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: var(--text-primary);
    background-color: #030712;
    min-height: 100vh;
    min-height: 100dvh; /* Dynamic mobile viewport height */
    position: relative;
    overflow-x: hidden;
}

/* Bulletproof fixed background for iOS, Android, and Desktop */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background-image: 
        radial-gradient(ellipse at 50% 25%, rgba(2, 132, 199, 0.35), transparent 70%),
        url('../img/hero-bg.png');
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    z-index: -2;
    transform: translateZ(0); /* Hardware acceleration */
}

/* Base dark tint overlay */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: rgba(3, 7, 18, 0.5);
    z-index: -1;
    pointer-events: none;
}

/* Site Shell */
.site-wrapper {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

/* ==========================================================================
   Header, Announcement Bar & Navigation
   ========================================================================== */

.site-header {
    width: 100%;
    position: relative;
    z-index: 10;
}

/* Top Announcement Bar - 3-Column Layout */
.announcement-bar {
    background: rgba(3, 105, 161, 0.35);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(56, 189, 248, 0.25);
    padding: 0.5rem 1.5rem;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    min-height: 48px;
    gap: 1rem;
}

/* Far Left Brand Badge */
.top-bar-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    text-decoration: none;
    justify-self: start;
    transition: transform 0.2s ease, filter 0.2s ease;
}

.top-bar-brand:hover {
    transform: translateY(-1px);
    filter: drop-shadow(0 0 8px rgba(56, 189, 248, 0.6));
}

/* Shield Badge Image */
.top-bar-logo {
    width: 32px;
    height: 32px;
    object-fit: contain;
    filter: drop-shadow(0 0 6px rgba(56, 189, 248, 0.35));
    display: block;
}

.top-bar-name {
    font-size: 0.9rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.top-bar-name span {
    font-weight: 400;
    color: var(--cyan-glow);
    text-shadow: 0 0 10px rgba(56, 189, 248, 0.35);
}

/* Center Tagline */
.announcement-text {
    text-align: center;
    font-size: 0.8rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #e0f2fe;
    white-space: nowrap;
}

.announcement-text span {
    font-weight: 600;
    color: #fff;
}

/* Right Spacer: Matches brand width on desktop so motto stays centered */
.top-bar-spacer {
    width: 220px;
    display: block;
}

/* Centered Floating Glass Navigation */
.glass-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 1.25rem;
    margin: 1.5rem auto 0;
    width: min(92%, 480px);
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 9999px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.glass-nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    padding: 0.45rem 1.1rem;
    border-radius: 9999px;
    transition: all 0.25s ease;
    white-space: nowrap;
}

.glass-nav a:hover,
.glass-nav a.active {
    color: #fff;
    background: rgba(56, 189, 248, 0.22);
    box-shadow: 0 0 14px rgba(56, 189, 248, 0.35);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero {
    text-align: center;
    padding: clamp(2rem, 6vw, 4.5rem) 1.5rem 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.9rem;
    background: rgba(15, 23, 42, 0.75);
    border: 1px solid var(--glass-border);
    border-radius: 9999px;
    font-size: 0.82rem;
    color: var(--cyan-glow);
    margin-bottom: 1.25rem;
    box-shadow: 0 0 16px rgba(56, 189, 248, 0.15);
}

.hero h1 {
    font-size: clamp(2rem, 6vw, 3.8rem);
    font-weight: 800;
    line-height: 1.18;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
}

.hero h1 span {
    color: var(--cyan-glow);
    text-shadow: 0 0 24px rgba(56, 189, 248, 0.6);
}

.hero p {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    color: #cbd5e1;
    max-width: 650px;
    margin: 0 auto;
    line-height: 1.6;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.75);
}

/* ==========================================================================
   Features Grid & Glass Cards
   ========================================================================== */

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
    gap: 1.5rem;
    max-width: 1100px;
    margin: 2rem auto 3.5rem;
    padding: 0 1.25rem;
    width: 100%;
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--glass-border);
    border-radius: 18px;
    padding: clamp(1.5rem, 4vw, 2rem);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.glass-card:hover {
    transform: translateY(-4px);
    border-color: var(--glass-border-hover);
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.45), 0 0 18px rgba(56, 189, 248, 0.3);
}

.glass-card:active {
    transform: scale(0.98);
}

.card-icon {
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: var(--cyan-glow);
    padding: 0.75rem;
    border-radius: 12px;
    margin-bottom: 1.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 12px rgba(56, 189, 248, 0.2);
}

.glass-card h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: #fff;
}

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

/* ==========================================================================
   Call To Action (CTA) Section
   ========================================================================== */

.cta-section {
    width: 100%;
    max-width: 800px;
    margin: 3rem auto 4.5rem;
    padding: 0 1.25rem;
    display: flex;
    justify-content: center;
}

.cta-card {
    width: 100%;
    text-align: center;
    align-items: center;
    padding: clamp(2rem, 5vw, 3rem);
    background: radial-gradient(ellipse at 50% 0%, rgba(56, 189, 248, 0.18), rgba(15, 23, 42, 0.8) 75%);
    border: 1px solid rgba(56, 189, 248, 0.4);
    border-radius: 18px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(56, 189, 248, 0.15);
}

.cta-card h2 {
    font-size: clamp(1.4rem, 3.5vw, 2rem);
    color: #fff;
    margin-bottom: 0.75rem;
}

.cta-card p {
    max-width: 550px;
    margin: 0 auto 1.75rem;
    color: var(--text-muted);
    font-size: 1rem;
}

/* Glowing Primary Button */
.btn-primary {
    display: inline-block;
    background: var(--cyan-glow);
    color: #030712;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.8rem 2rem;
    border-radius: 9999px;
    text-decoration: none;
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.45);
    transition: all 0.25s ease;
}

.btn-primary:hover {
    background: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 0 28px rgba(56, 189, 248, 0.8);
}

.btn-primary:active {
    transform: scale(0.97);
}

/* ==========================================================================
   Assessment Form Integration
   ========================================================================== */

.form-hero {
    padding-bottom: 1rem;
}

.form-container-section {
    max-width: 900px;
    width: 100%;
    margin: 0 auto 4rem;
    padding: 0 1.25rem;
    display: flex;
    justify-content: center;
}

.form-card {
    width: 100%;
    padding: 0.5rem;
    border-radius: 20px;
    overflow: hidden;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5), 0 0 25px rgba(56, 189, 248, 0.15);
}

.ms-form-frame {
    width: 100%;
    height: 820px;
    border: none;
    border-radius: 14px;
    background: transparent;
    display: block;
}

/* ==========================================================================
   About Page Specifics
   ========================================================================== */

.principles-list {
    list-style: none;
    padding: 0;
    margin: 1.25rem 0 2rem 0;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 600px;
}

.principles-list li {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
    position: relative;
    padding-left: 1.5rem;
}

.principles-list li::before {
    content: '✔';
    position: absolute;
    left: 0;
    color: var(--cyan-glow);
    font-size: 0.9rem;
}

.principles-list li strong {
    color: #fff;
}

/* ==========================================================================
   Footer
   ========================================================================== */

footer {
    margin-top: auto;
    padding: 1.5rem 1rem 2rem;
}

.footer-glass {
    max-width: 800px;
    margin: 0 auto;
    padding: 1rem;
    text-align: center;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 900px) {
    .top-bar-spacer {
        display: none;
    }

    .announcement-bar {
        display: flex;
        flex-direction: column;
        gap: 0.4rem;
        padding: 0.65rem 1rem;
    }

    .top-bar-brand {
        justify-self: center;
    }

    .announcement-text {
        font-size: 0.75rem;
    }
}

@media (max-width: 768px) {
    .glass-nav {
        width: calc(100% - 2rem);
        justify-content: space-around;
        padding: 0.5rem;
        gap: 0.25rem;
    }

    .glass-nav a {
        padding: 0.4rem 0.75rem;
        font-size: 0.88rem;
    }
}

@media (max-width: 640px) {
    .form-card {
        padding: 0.25rem;
        border-radius: 16px;
    }

    .ms-form-frame {
        height: 880px;
    }
}

@media (max-width: 480px) {
    .top-bar-logo {
        width: 26px;
        height: 26px;
    }

    .top-bar-name {
        font-size: 0.82rem;
    }

    .announcement-text {
        font-size: 0.68rem;
    }

    .hero-badge {
        font-size: 0.78rem;
    }

    .glass-card {
        padding: 1.4rem;
    }

    .glass-nav {
        width: calc(100% - 1.5rem);
        gap: 0.2rem;
        padding: 0.35rem 0.5rem;
    }

    .glass-nav a {
        font-size: 0.82rem;
        padding: 0.35rem 0.65rem;
    }
}

/* ==========================================================================
   Comprehensive Site Footer (Cyber-Glass Aesthetic)
   ========================================================================== */
.site-footer {
  background: rgba(10, 15, 30, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  font-size: 0.88rem;
  padding-top: 3.5rem;
  margin-top: 5rem;
  position: relative;
  z-index: 10;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem 3rem 1.5rem;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 0.8fr;
  gap: 2.5rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.footer-logo {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.footer-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #f8fafc;
  letter-spacing: -0.02em;
}

.footer-title span {
  color: #38bdf8;
}

.footer-desc {
  font-size: 0.82rem;
  line-height: 1.5;
  color: #94a3b8;
  margin-bottom: 1.25rem;
}

.footer-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.footer-badges .pill {
  font-size: 0.75rem;
  font-weight: 600;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.2);
  padding: 3px 8px;
  border-radius: 4px;
}

.footer-heading {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #f8fafc;
  margin-bottom: 1.2rem;
}

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

.footer-links li,
.footer-checklist li,
.footer-nav li {
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.82rem;
}

.footer-links a,
.footer-nav a {
  color: #94a3b8;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-links a:hover,
.footer-nav a:hover {
  color: #38bdf8;
}

.footer-icon {
  font-size: 1rem;
}

.footer-checklist li {
  position: relative;
  padding-left: 1.1rem;
  color: #cbd5e1;
}

.footer-checklist li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: #38bdf8;
  font-size: 1.1rem;
  line-height: 1;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(5, 8, 18, 0.95);
  padding: 1.25rem 0;
  font-size: 0.78rem;
  color: #64748b;
}

.footer-bottom-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.tagline {
  color: #94a3b8;
  font-weight: 500;
}

@media (max-width: 992px) {
  .footer-container {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

@media (max-width: 580px) {
  .footer-container {
    grid-template-columns: 1fr;
  }
  .footer-bottom-inner {
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
  }
}