/* ─── Variables ──────────────────────────────────────────────────────────── */
:root {
    --bg:          #0e1a2b;
    --bg-card:     #131f33;
    --bg-nav:      rgba(10, 18, 32, 0.96);
    --text:        #c8d8e8;
    --text-muted:  #6a8aaa;
    --text-heading:#e4edf6;
    --accent:      #4a9eff;
    --accent-dark: #1a4a7a;
    --pcb-trace:   rgba(74, 158, 255, 0.28);
    --nav-height:  64px;
}

/* ─── Reset / Base ────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    font-family: 'Open Sans', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
}

/* ─── Typography ──────────────────────────────────────────────────────────── */
h1, h2, h3, h4 {
    font-family: 'Lora', Georgia, serif;
    color: var(--text-heading);
    line-height: 1.25;
}

p { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }

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

/* ─── Navbar ──────────────────────────────────────────────────────────────── */
.navbar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    height: var(--nav-height);
    display: flex; align-items: center;
    padding: 0 2rem;
    background: transparent;
    transition: background 0.3s, box-shadow 0.3s;
}

.navbar.is-scrolled {
    background: var(--bg-nav);
    backdrop-filter: blur(8px);
    box-shadow: 0 1px 0 rgba(74, 158, 255, 0.12);
}

.navbar-inner {
    max-width: 1100px; width: 100%; margin: 0 auto;
    display: flex; align-items: center; gap: 2rem;
}

.navbar-brand {
    font-family: 'Lora', Georgia, serif;
    font-size: 1.2rem; font-weight: 600;
    color: #fff !important;
    text-decoration: none !important;
    white-space: nowrap;
}

.navbar-links {
    display: flex; list-style: none; gap: 2rem; margin-left: auto;
}

.navbar-links a {
    color: rgba(228, 237, 246, 0.85);
    font-size: 0.875rem; font-weight: 600;
    letter-spacing: 0.06em; text-transform: uppercase;
    text-decoration: none;
    transition: color 0.2s;
}

.navbar-links a:hover { color: var(--accent); text-decoration: none; }

.navbar-toggle {
    display: none; margin-left: auto;
    background: none; border: none; cursor: pointer; padding: 0.5rem;
    flex-direction: column; gap: 5px;
}

.navbar-toggle span {
    display: block; width: 24px; height: 2px;
    background: #fff; border-radius: 2px;
    transition: all 0.3s;
}

/* ─── Masthead ────────────────────────────────────────────────────────────── */
.masthead {
    position: relative; overflow: hidden;
    min-height: 55vh;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(145deg, #08111e 0%, #0e1a2b 55%, #0a1525 100%);
}

.masthead.is-hero { min-height: 100vh; }

.masthead-pcb {
    position: absolute; inset: 0; width: 100%; height: 100%;
    object-fit: cover;
}

.masthead-inner {
    position: relative; z-index: 1;
    text-align: center;
    padding: calc(var(--nav-height) + 3rem) 2rem 3rem;
    max-width: 800px; width: 100%;
}

.masthead-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    color: #ffffff;
    letter-spacing: -0.02em;
    margin-bottom: 1.25rem;
}

.masthead-tagline {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: rgba(200, 216, 232, 0.8);
    max-width: 520px; margin: 0 auto 2.5rem;
    line-height: 1.6;
}

.masthead-cta {
    display: inline-block;
    padding: 0.9rem 2.75rem;
    background: var(--accent);
    color: #fff !important;
    border-radius: 4px;
    font-weight: 600; font-size: 1rem;
    letter-spacing: 0.04em;
    text-decoration: none !important;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    box-shadow: 0 4px 20px rgba(74, 158, 255, 0.3);
}

.masthead-cta:hover {
    background: #3a8ef0;
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(74, 158, 255, 0.45);
}

/* ─── Sections ────────────────────────────────────────────────────────────── */
.section { padding: 5rem 2rem; }
.section-alt { background: var(--bg-card); }

.section-inner { max-width: 960px; margin: 0 auto; }

.section-title {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    margin-bottom: 1.5rem;
    position: relative; padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute; bottom: 0; left: 0;
    width: 48px; height: 3px;
    background: var(--accent); border-radius: 2px;
}

.section-lead {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 640px; margin-bottom: 3rem;
    line-height: 1.8;
}

/* ─── Services grid ───────────────────────────────────────────────────────── */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
}

.service-card {
    background: var(--bg);
    border: 1px solid rgba(74, 158, 255, 0.12);
    border-radius: 6px;
    padding: 1.75rem;
    transition: border-color 0.2s, transform 0.15s;
}

.service-card:hover {
    border-color: rgba(74, 158, 255, 0.4);
    transform: translateY(-3px);
}

.service-card h3 {
    font-size: 1.05rem; margin-bottom: 0.75rem;
    color: var(--text-heading);
}

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

/* ─── Contact ─────────────────────────────────────────────────────────────── */
.contact-intro {
    font-size: 1.1rem; color: var(--text-muted);
    margin-bottom: 1.75rem; max-width: 520px;
}

.contact-form { max-width: 520px; }

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

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

.form-group input,
.form-group textarea {
    width: 100%;
    background: var(--bg);
    border: 1px solid rgba(74, 158, 255, 0.2);
    border-radius: 4px;
    color: var(--text);
    font-family: inherit; font-size: 0.95rem;
    padding: 0.65rem 0.875rem;
    transition: border-color 0.2s;
    resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-muted); }

.btn-submit {
    display: inline-block;
    padding: 0.75rem 2rem;
    background: var(--accent);
    color: #fff;
    border: none; border-radius: 4px;
    font-family: inherit; font-size: 1rem; font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
}

.btn-submit:hover:not(:disabled) {
    background: #3a8ef0;
    transform: translateY(-1px);
}

.btn-submit:disabled { opacity: 0.6; cursor: not-allowed; }

.form-status { margin-top: 0.75rem; font-size: 0.9rem; min-height: 1.25em; }
.form-status.is-success { color: #4ade80; }
.form-status.is-error   { color: #f87171; }

/* ─── Footer ──────────────────────────────────────────────────────────────── */
.site-footer {
    background: #060d18;
    border-top: 1px solid rgba(74, 158, 255, 0.1);
    padding: 2.5rem 2rem;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.footer-inner p + p { margin-top: 0.4rem; }

/* ─── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
    .navbar-links { display: none; }

    .navbar-links.is-open {
        display: flex; flex-direction: column; gap: 0;
        position: absolute; top: var(--nav-height); left: 0; right: 0;
        background: var(--bg-nav);
        padding: 1rem 2rem 1.5rem;
        border-top: 1px solid rgba(74, 158, 255, 0.1);
    }

    .navbar-links.is-open li { padding: 0.5rem 0; }
    .navbar-toggle { display: flex; }
    .services-grid { grid-template-columns: 1fr; }
}
