/* =========================================
   MEDILOOP WEBSITES - AGENCY STYLES
   ========================================= */

body, html {
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
    background-color: #050505; /* Extremely dark, sleek background */
    color: #F3F4F6;
    scroll-behavior: smooth;
    overflow-x: hidden;
}

/* --- NAVIGATION --- */
.agency-nav {
    position: fixed;
    top: 0; width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px;
    box-sizing: border-box;
    background: rgba(5, 5, 5, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 1000;
}
.nav-logo {
    font-size: 1.2rem;
    letter-spacing: 1px;
}
.logo-bold { font-weight: 800; color: #FFFFFF; }
.logo-light { font-weight: 300; color: #9CA3AF; }

.nav-links a {
    color: #D1D5DB;
    text-decoration: none;
    margin-left: 30px;
    font-size: 0.9rem;
    font-weight: 400;
    transition: color 0.3s;
}
.nav-links a:hover { color: #FFFFFF; }

.btn-nav {
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 10px 20px;
    border-radius: 8px;
    transition: all 0.3s;
}
.btn-nav:hover { background: #FFFFFF; color: #050505 !important; }

/* --- HERO SECTION --- */
.agency-hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    padding: 0 20px;
}
.hero-container {
    position: relative;
    z-index: 2;
    max-width: 900px;
}
.hero-badge {
    display: inline-block;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(139, 92, 246, 0.3); /* Subtle violet border */
    border-radius: 50px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #E5E7EB;
    margin-bottom: 30px;
}
.hero-title {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin: 0 0 25px 0;
    letter-spacing: -1px;
}
/* Deep Violet to Magenta Gradient */
.highlight {
    color: transparent;
    background-image: linear-gradient(90deg, #8B5CF6, #D946EF); 
    -webkit-background-clip: text;
    background-clip: text;
}
.hero-subtitle {
    font-size: 1.2rem;
    color: #9CA3AF;
    font-weight: 300;
    line-height: 1.6;
    max-width: 700px;
    margin: 0 auto 50px auto;
}
.hero-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
}
/* Software Brand Button */
.btn-primary {
    display: inline-block;
    background: linear-gradient(90deg, #8B5CF6, #D946EF);
    color: #FFFFFF;
    text-decoration: none;
    padding: 16px 35px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}
.btn-primary:hover { 
    transform: translateY(-3px); 
    box-shadow: 0 10px 25px rgba(217, 70, 239, 0.3); 
}
.btn-secondary {
    display: inline-block;
    background: transparent;
    color: #FFFFFF;
    text-decoration: none;
    padding: 16px 35px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s;
}
.btn-secondary:hover { background: rgba(255, 255, 255, 0.1); }

/* Violet Tech Glow */
.hero-glow {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 600px; height: 600px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
    z-index: 1;
}

/* --- THE SHOWROOM SECTION --- */
.showroom-section {
    padding: 100px 20px 140px 20px;
    background-color: #0A0A0A;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.showroom-container {
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
}
.showroom-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -1px;
    margin: 0 0 15px 0;
}
.showroom-header p {
    color: #9CA3AF;
    font-size: 1.1rem;
    margin: 0 auto 50px auto;
    max-width: 600px;
    line-height: 1.6;
}

/* Browser Mockup styling for the portfolio piece */
.browser-mockup {
    background: #111111;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(139, 92, 246, 0.1);
    position: relative;
}
.browser-top {
    background: #1A1A1A;
    padding: 15px 20px;
    display: flex;
    gap: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.dot {
    width: 12px; height: 12px;
    border-radius: 50%;
}
.dot.red { background-color: #FF5F56; }
.dot.yellow { background-color: #FFBD2E; }
.dot.green { background-color: #27C93F; }

.browser-content {
    position: relative;
    width: 100%;
    height: 500px; /* Gives a good preview window size */
}
.preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top; /* Ensures the top of the spa template shows */
    transition: filter 0.4s;
}
.preview-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(5, 5, 5, 0.7);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s;
}
.browser-content:hover .preview-img {
    filter: blur(3px);
}
.browser-content:hover .preview-overlay {
    opacity: 1;
}

/* Tech Features below the mockup */
.showroom-features {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 40px;
}
.feature-tag {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 10px 20px;
    border-radius: 50px;
    font-size: 0.85rem;
    color: #D1D5DB;
    letter-spacing: 0.5px;
}

/* --- THE ECOSYSTEM SECTION --- */
.ecosystem-section {
    padding: 120px 20px;
    background-color: #050505;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
}
/* Subtle magenta background glow behind the grid */
.ecosystem-section::before {
    content: '';
    position: absolute;
    top: 40%; left: 50%;
    transform: translate(-50%, -50%);
    width: 800px; height: 500px;
    background: radial-gradient(circle, rgba(217, 70, 239, 0.05) 0%, transparent 60%);
    z-index: 1;
    pointer-events: none;
}
.ecosystem-container {
    max-width: 1100px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}
.ecosystem-header {
    text-align: center;
    margin-bottom: 70px;
}
.ecosystem-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -1px;
    margin: 0 0 15px 0;
}
.ecosystem-header p {
    color: #9CA3AF;
    font-size: 1.1rem;
    margin: 0 auto;
    max-width: 600px;
    line-height: 1.6;
}

/* The 3-Column Tech Grid */
.ecosystem-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}
.eco-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 40px 30px;
    transition: all 0.4s ease;
    backdrop-filter: blur(10px);
}
.eco-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(139, 92, 246, 0.4); /* Violet border on hover */
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(139, 92, 246, 0.1);
}
.eco-icon {
    font-size: 2.5rem;
    margin-bottom: 25px;
    background: -webkit-linear-gradient(90deg, #8B5CF6, #D946EF);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}
.eco-card h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0 0 15px 0;
    color: #FFFFFF;
}
.eco-card p {
    color: #9CA3AF;
    font-size: 0.95rem;
    line-height: 1.7;
    margin: 0;
}

/* --- CTA / DEMO SECTION --- */
.cta-section {
    padding: 100px 20px;
    background: #050505;
    text-align: center;
    position: relative;
}
.cta-container {
    max-width: 800px;
    margin: 0 auto;
    background: rgba(139, 92, 246, 0.03); /* Extremely subtle violet box */
    border: 1px solid rgba(139, 92, 246, 0.15);
    padding: 70px 40px;
    border-radius: 24px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    transition: transform 0.4s, border-color 0.4s;
}
.cta-container:hover {
    transform: translateY(-5px);
    border-color: rgba(217, 70, 239, 0.3); /* Shifts to magenta on hover */
}
.cta-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin: 0 0 20px 0;
    color: #FFFFFF;
}
.cta-desc {
    color: #9CA3AF;
    font-size: 1.1rem;
    line-height: 1.6;
    margin: 0 auto 40px auto;
    max-width: 600px;
}

/* --- AGENCY FOOTER --- */
.agency-footer {
    background-color: #000000; /* True black to anchor the page */
    padding: 80px 50px 30px 50px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    max-width: 1100px;
    margin: 0 auto 60px auto;
}
.footer-brand p {
    color: #9CA3AF;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-top: 15px;
    max-width: 320px;
}
.footer-grid h4 {
    color: #FFFFFF;
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 20px 0;
}
.footer-grid p {
    color: #9CA3AF;
    font-size: 0.9rem;
    line-height: 1.8;
    margin: 0;
}
.footer-grid a {
    color: #9CA3AF;
    font-size: 0.9rem;
    line-height: 1.8;
    text-decoration: none;
    display: block;
    transition: color 0.3s;
}
.footer-grid a:hover {
    color: #D946EF; /* Magenta hover effect for links */
}
.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: #6B7280;
    font-size: 0.85rem;
}

/* --- MOBILE RESPONSIVE --- */
@media (max-width: 768px) {
    .agency-nav { padding: 15px; }
    .nav-links { display: none; } /* Kept hidden on mobile for clean look */
    .hero-title { font-size: 2.5rem; }
    .hero-subtitle { font-size: 1rem; }
    .hero-actions { flex-direction: column; }
    .browser-content { height: 300px; }
    .preview-overlay { opacity: 1; background: rgba(5, 5, 5, 0.5); } /* Always show button on mobile */
    .showroom-features { gap: 10px; }
    .feature-tag { padding: 8px 15px; font-size: 0.75rem; }
    .ecosystem-grid { grid-template-columns: 1fr; gap: 20px; }

    /* Mobile Fixes for CTA and Footer */
    .cta-container { padding: 50px 20px; }
    .cta-title { font-size: 2rem; }
    .agency-footer { padding: 60px 20px 20px 20px; }
    .footer-grid { grid-template-columns: 1fr; gap: 40px; }
}
