/* ================= RESEARCH CORE VARIABLES ================= */
:root {
    --brand-red: #E3000F;
    --brand-red-glow: rgba(227, 0, 15, 0.3);
    --bg-pure: #FFFFFF;
    --bg-off: #F8F8F9;
    --bg-dark: #09090B;
    --text-main: #09090B;
    --text-muted: #71717A;
    --border-hw: #E4E4E7;
    
    /* Font Alignment with index.html */
    --font-main: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Layout Reset & Global Styles */
* { margin: 0; padding: 0; box-sizing: border-box; }

body { 
    font-family: var(--font-main); 
    background-color: var(--bg-pure); 
    color: var(--text-main); 
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }

/* Technical Typography */
.sys-code { 
    font-family: var(--font-mono); 
    font-size: 0.7rem; 
    letter-spacing: 2px; 
    color: var(--brand-red); 
    font-weight: 700; 
    text-transform: uppercase; 
}

.section-heading { 
    font-family: var(--font-main);
    font-size: 3.5rem; 
    font-weight: 800; 
    margin-top: 10px; 
    text-transform: uppercase; 
    letter-spacing: -0.03em;
}

.schematic-bg { 
    background-image: radial-gradient(#d1d1d6 1px, transparent 1px); 
    background-size: 30px 30px; 
}

/* ================= NAVIGATION ================= */
.system-bar { background-color: var(--bg-dark); color: var(--bg-pure); padding: 8px 0; border-bottom: 2px solid var(--brand-red); }
.sys-flex { display: flex; justify-content: space-between; align-items: center; }
.status-dot { display: inline-block; width: 6px; height: 6px; background-color: #10B981; border-radius: 50%; box-shadow: 0 0 8px #10B981; }

.hardware-nav { padding: 20px 0; border-bottom: 1px solid var(--border-hw); position: sticky; top: 0; background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(8px); z-index: 100; }
.nav-wrapper { display: flex; justify-content: space-between; align-items: center; }
.brand-logo { height: 50px; width: auto; object-fit: contain; }
.nav-links { display: flex; gap: 40px; }
.nav-links a { font-family: var(--font-mono); font-size: 0.85rem; font-weight: 700; }
.nav-links a:hover { color: var(--brand-red); }
.nav-links .mobile-contact { display: none; }
.desktop-contact { display: inline-flex; }

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle .bar {
    height: 3px;
    width: 100%;
    background-color: var(--bg-dark);
    transition: var(--transition);
}

@media (max-width: 1024px) {
    .nav-wrapper {
        flex-direction: row;
        justify-content: space-between;
        padding: 15px 24px;
    }

    .menu-toggle { display: flex; order: 2; }
    .logo-container { order: 1; }
    .nav-links { display: none; }
    .desktop-contact { display: none; }
    .nav-links .mobile-contact { display: inline-flex; }

    .nav-links {
        position: fixed;
        left: -100%;
        top: 80px;
        flex-direction: column;
        background-color: var(--bg-pure);
        width: 100%;
        height: calc(100vh - 80px);
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
        padding: 40px 0;
        display: flex;
        z-index: 999;
    }

    .nav-links.active { left: 0; }
    .nav-links li { margin: 20px 0; }
    .nav-links a { font-size: 1.2rem; }
    .nav-links .mobile-contact { margin: 20px 0; }

    .menu-toggle.active .bar:nth-child(2) { opacity: 0; }
    .menu-toggle.active .bar:nth-child(1) { transform: translateY(9px) rotate(45deg); }
    .menu-toggle.active .bar:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }
}
/* ================= MISSION / HERO SECTION ================= */
.res-hero {
    padding: 140px 0 100px;
    background-color: var(--bg-pure);
    border-bottom: 1px solid var(--border-hw);
}

.res-main-title {
    font-family: var(--font-main);
    font-weight: 800;
    font-size: 5.5rem;
    line-height: 0.9;
    letter-spacing: -0.04em;
    text-transform: uppercase;
    margin: 30px 0;
}

.res-subtitle {
    max-width: 700px;
    color: var(--text-muted);
    font-size: 1.2rem;
    line-height: 1.6;
    border-left: 4px solid var(--brand-red);
    padding-left: 30px;
}

/* ================= VIRTUAL LAB CARDS ================= */
.lab-grid-section { padding: 100px 0; background: var(--bg-off); }

.lab-layout {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.lab-card {
    background: var(--bg-pure);
    padding: 50px 40px;
    border: 1px solid var(--border-hw);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.lab-card:hover {
    transform: translateY(-10px);
    border-color: var(--brand-red);
    box-shadow: 0 20px 40px rgba(0,0,0,0.05);
}

.lab-card h3 {
    font-family: var(--font-main);
    font-size: 1.75rem;
    font-weight: 800;
    margin-bottom: 15px;
}

.active-lab {
    background: var(--bg-dark);
    color: white;
    border-color: var(--brand-red);
    box-shadow: 0 15px 35px var(--brand-red-glow);
}

.lab-tag {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    margin-bottom: 25px;
    display: inline-block;
    padding: 4px 10px;
    background: var(--bg-off);
    color: var(--text-muted);
    font-weight: 700;
    align-self: flex-start;
}

.active-lab .lab-tag { background: #1c1c1f; color: var(--brand-red); }

.btn-link {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--brand-red);
    font-weight: 700;
    text-decoration: underline;
    margin-top: auto; 
    padding-top: 20px;
    display: inline-block;
}

/* ================= NEWS TICKER SECTION ================= */
.news-section { padding: 40px 0; border-top: 1px solid var(--border-hw); background: white; }
.ticker-wrap { overflow: hidden; background: var(--bg-off); padding: 15px; border: 1px solid var(--border-hw); }
.ticker { display: flex; white-space: nowrap; animation: ticker 40s linear infinite; }
.news-item { 
    margin-right: 80px; 
    font-family: var(--font-mono); 
    font-size: 0.85rem; 
    color: var(--text-main); 
    font-weight: 600; 
}

@keyframes ticker {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* ================= CONTACT FORM SECTION ================= */
.contact-form-section { padding: 100px 0; border-top: 1px solid var(--border-hw); }
.contact-flex { display: grid; grid-template-columns: 1fr 1.5fr; gap: 60px; }

.res-form { display: flex; flex-direction: column; gap: 20px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.res-form input, .res-form textarea {
    background: white;
    border: 1px solid var(--border-hw);
    padding: 18px;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    outline: none;
    transition: 0.3s;
}

.res-form input:focus, .res-form textarea:focus {
    border-color: var(--brand-red);
    box-shadow: 0 0 10px var(--brand-red-glow);
}

.res-form textarea { grid-column: span 2; resize: none; }

.btn-solid {
    background: var(--brand-red);
    color: white;
    padding: 20px 40px;
    font-family: var(--font-mono);
    font-weight: 700;
    border: none;
    cursor: pointer;
    text-transform: uppercase;
    transition: 0.3s;
    align-self: flex-start;
}

.btn-solid:hover { background: var(--bg-dark); transform: translateY(-3px); }

/* ================= FOOTER POLISH ================= */
.hardware-footer { background: var(--bg-dark); color: white; padding: 80px 0 40px; }
.footer-bottom { 
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    border-top: 1px solid #27272A;
    padding-top: 40px;
    margin-top: 40px;
}

.footer-links a { margin-left: 20px; font-size: 0.75rem; color: var(--text-muted); transition: 0.2s; text-decoration: none; }
.footer-links a:hover { color: var(--brand-red); }

/* ================= RESPONSIVE ================= */
@media (max-width: 1024px) {
    .res-main-title { font-size: 3.5rem; }
    .contact-flex, .lab-layout { grid-template-columns: 1fr; gap: 40px; }
    .form-grid { grid-template-columns: 1fr; }
    .res-form textarea { grid-column: span 1; }
    .footer-bottom { flex-direction: column; gap: 20px; text-align: center; }
    .footer-links a { margin: 0 10px; }
}

@media (max-width: 768px) {
    .res-hero { padding: 100px 0 80px; }
    .res-main-title { font-size: 2.8rem; }
    .res-subtitle { font-size: 1rem; padding-left: 20px; max-width: none; }
    
    .lab-grid-section { padding: 80px 0; }
    .section-heading { font-size: 2.5rem; }
    .lab-card { padding: 40px 30px; }
    .lab-card h3 { font-size: 1.5rem; }
    .lab-card p { font-size: 0.9rem; }
    
    .news-section { padding: 30px 0; }
    .ticker-wrap { padding: 12px; }
    .news-item { font-size: 0.8rem; margin-right: 40px; }
    
    .contact-form-section { padding: 80px 0; }
    .contact-info h2 { font-size: 2rem; }
    .contact-info p { font-size: 0.95rem; }
    .res-form { gap: 15px; }
    .form-grid { gap: 15px; }
    .res-form input, .res-form textarea { padding: 15px; font-size: 0.8rem; }
    .btn-solid { padding: 16px 32px; font-size: 0.8rem; }
    
    .hardware-footer { padding: 60px 0 30px; }
}

@media (max-width: 480px) {
    .res-main-title { font-size: 2.2rem; }
    .section-heading { font-size: 1.8rem; }
    .lab-card { padding: 30px 20px; }
}