/* noMadAI Labs: Refined Design System */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;700;900&display=swap');

:root {
    --bg-color: #000000;
    --text-primary: #ffffff;
    --text-secondary: #aaaaaa;
    --accent-blue: #0076FF;
    --theme-color: var(--accent-blue);
    --transition-studio: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    cursor: default;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    min-height: 100vh;
    opacity: 0;
    transition: opacity 1.2s cubic-bezier(0.19, 1, 0.22, 1);
}

body.revealed { opacity: 1; }
body.fading { opacity: 0 !important; }

#particleCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

/* --- Agency Header System --- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 3rem 5rem;
    z-index: 500;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8), transparent);
}

.logo-container {
    position: relative;
    font-size: 26px;
    font-weight: 900;
    color: var(--accent-blue);
    cursor: pointer;
    text-align: left;
    white-space: nowrap;
}

.logo-container::after {
    content: "noMadAI Labs";
    position: absolute;
    left: 0;
    top: 100%;
    width: 100%;
    transform: scaleY(-1);
    opacity: 0.15;
    background: linear-gradient(to top, var(--accent-blue), transparent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    pointer-events: none;
    margin-top: -10px;
}

.top-menu {
    display: flex;
    gap: 3rem;
    list-style: none;
}

.menu-item {
    position: relative;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2rem;
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition-studio);
    cursor: pointer;
    padding-bottom: 10px;
}

.indicator-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: var(--theme-color);
    transition: width 0.5s cubic-bezier(0.19, 1, 0.22, 1);
    box-shadow: 0 0 10px var(--theme-color);
}

.menu-item:hover .indicator-bar { width: 100%; }

/* Typography & Hero */
.hero-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 10%;
    max-width: 1400px;
}

.hero-main { 
    font-size: 5rem; 
    font-weight: 900; 
    line-height: 1.1; 
    margin-bottom: 2rem;
    max-width: 1100px;
}

.hero-sub { 
    font-size: 1.2rem; 
    color: var(--text-secondary); 
    line-height: 1.8; 
    max-width: 800px;
    margin-bottom: 3rem;
}

.cta-group {
    display: flex;
    gap: 2rem;
}

.cta-button {
    padding: 1rem 2rem;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1rem;
    color: #fff;
    border: 1px solid var(--accent-blue);
    text-decoration: none;
    transition: var(--transition-studio);
    cursor: pointer;
}

.cta-button:hover {
    background: rgba(0, 118, 255, 0.2);
    box-shadow: 0 0 20px rgba(0, 118, 255, 0.3);
}

/* Sections */
.content-section {
    padding: 8rem 10%;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    font-size: 3.5rem;
    font-weight: 900;
    margin-bottom: 3rem;
    color: var(--accent-blue);
}

.text-block {
    font-size: 1.2rem;
    line-height: 2;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 900px;
}

.text-block strong { color: #fff; }

/* Grid specific */
.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 4rem;
    margin-top: 5rem;
}

.service-item { cursor: pointer; position: relative; transition: var(--transition-studio); padding-bottom: 15px; }

.product-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: var(--theme-color);
    transition: var(--transition-studio);
    box-shadow: 0 0 10px var(--theme-color);
}

.service-item:hover .product-bar { width: 100%; }

.service-title { font-size: 1rem; font-weight: 700; text-transform: uppercase; margin-bottom: 1rem; cursor: pointer; }
.service-desc { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.6; }

/* Modals */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(40px);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition-studio);
}

.overlay.active { opacity: 1; pointer-events: all; }

.modal-content { max-width: 1400px; padding: 4rem; width: 95%; max-height: 90vh; overflow-y: auto; }
.modal-close { position: absolute; top: 3rem; right: 3rem; font-size: 0.8rem; font-weight: 700; color: var(--text-secondary); cursor: pointer; text-transform: uppercase; }

/* Footer */
footer {
    padding: 6rem 10% 4rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    margin-top: 8rem;
    text-align: center;
}

.footer-disclaimer {
    font-size: 0.75rem;
    color: #666;
    max-width: 800px;
    margin: 0 auto 2rem;
    line-height: 1.8;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
}
.footer-links a { color: #888; text-decoration: none; font-size: 0.85rem; transition: color 0.3s; }
.footer-links a:hover { color: #fff; }

/* Swarm Canvas Styles */
.swarm-container {
    width: 100%;
    height: 500px;
    margin-top: 4rem;
    border-radius: 12px;
    background: rgba(10, 10, 15, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 40px rgba(0, 118, 255, 0.05);
}

#swarmCanvas {
    width: 100%;
    height: 100%;
    display: block;
}
