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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #ffffff;
    background: #161c2a;
    overflow-x: hidden;
}

/* Authentic Lega Background Pattern */
.bg-pattern {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background:
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="%23ff2d8f" opacity="0.1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>'),
        radial-gradient(ellipse at right, rgba(121,58,255,0.65) 0%, rgba(255,255,255,0) 72%),
        linear-gradient(180deg, rgba(255,255,255,0) 70%, rgba(4,5,53,0.54) 100%);
    background-size: 100px 100px, 100% 100%, 100% 100%;
    background-position: 0 0, center top, center top;
    animation: float 30s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) translateX(0px); }
    25% { transform: translateY(-10px) translateX(5px); }
    50% { transform: translateY(5px) translateX(-3px); }
    75% { transform: translateY(-3px) translateX(7px); }
}

/* Header */
.header {
    background: rgba(22, 28, 42, 0.99);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.5rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 0 rgba(0,0,0,.1);
}

.container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 20px;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
    text-decoration: none;
}

.logo-img {
    height: 32px;
    width: auto;
    max-width: 120px;
}

.logo-fallback {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    font-size: 1.5rem;
    color: #ffffff;
}

.logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: rgba(242, 242, 242, 0.83);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    position: relative;
}

.nav-links a:hover {
    color: #09b9f3;
    opacity: 0.7;
}

/* Hero Section */
.hero {
    background:
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="brain-pattern" width="50" height="50" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="2" fill="%23ff2d8f" opacity="0.15"/><circle cx="10" cy="40" r="1.5" fill="%2309b9f3" opacity="0.1"/><circle cx="40" cy="15" r="1" fill="%23ffffff" opacity="0.05"/></pattern></defs><rect width="100%" height="100%" fill="url(%23brain-pattern)"/></svg>'),
        linear-gradient(135deg, rgba(255, 45, 143, 0.2) 0%, rgba(9, 185, 243, 0.1) 50%, transparent 100%);
    background-size: 200px 200px, 100% 100%;
    padding: 60px 0 60px 0;
    text-align: left;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 50%;
    right: 10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 45, 143, 0.1) 0%, transparent 70%);
    transform: translate(50%, -50%);
    border-radius: 50%;
    animation: pulse 8s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: translate(50%, -50%) scale(1); opacity: 0.3; }
    50% { transform: translate(50%, -50%) scale(1.2); opacity: 0.6; }
}

.hero-content {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text {
    max-width: 600px;
}

.hero-subtitle {
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    color: #ff2d8f;
    letter-spacing: 1px;
    line-height: 1.5em;
    font-size: 16px;
    margin-bottom: 10px;
}

.hero h1 {
    font-family: 'Inter', sans-serif;
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    letter-spacing: -2px;
    color: #ffffff;
    line-height: 1.1;
}

.hero p {
    font-size: 1.2rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.75);
    max-width: 500px;
    line-height: 1.8em;
    margin-bottom: 2rem;
}

.hero .mcp-link {
    color: #09b9f3;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(9, 185, 243, 0.3);
}

.hero .mcp-link:hover {
    border-bottom-color: #09b9f3;
    text-shadow: 0 0 8px rgba(9, 185, 243, 0.5);
}

.brain-visual {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.brain-container {
    width: 300px;
    height: 300px;
    position: relative;
    margin-top: -60px;
}

.brain-svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 20px rgba(255, 45, 143, 0.3));
    animation: brainFloat 6s ease-in-out infinite;
}

@keyframes brainFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(2deg); }
}

/* Action Buttons */
.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.btn {
    display: inline-block;
    padding: 16px 24px;
    border-radius: 100px;
    text-decoration: none;
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    transition: all 0.3s ease;
    text-align: center;
    cursor: pointer;
    border: 1px solid;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.6s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: #09b9f3;
    color: #ffffff;
    border-color: #09b9f3;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(9, 185, 243, 0.4);
}

.btn-secondary {
    background: transparent;
    color: #ffffff;
    border-color: #ffffff;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* Features Section */
.features-section {
    padding: 80px 0;
    position: relative;
}

.features-intro {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 3rem;
    margin-bottom: 4rem;
    align-items: center;
}

.features-label {
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 20px;
    color: #ff2d8f;
    letter-spacing: 1px;
    line-height: 1.5em;
}

.features-title {
    font-family: 'Inter', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.2em;
    margin-bottom: 1rem;
}

.features-description {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.8em;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 3rem;
    margin-top: 2rem;
}

.feature-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 2.5rem;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(20px);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, #ff2d8f, #09b9f3);
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(255, 45, 143, 0.15);
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 45, 143, 0.3);
}

.feature-icon {
    width: 64px;
    height: 64px;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 10px rgba(9, 185, 243, 0.3));
}

.feature-title {
    font-family: 'Inter', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1rem;
    line-height: 1.4em;
}

.feature-description {
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.8em;
}

/* Servers Section */
.servers-section {
    padding: 5rem 0;
    position: relative;
}

.section-title {
    font-family: 'Inter', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: #ffffff;
    text-align: center;
    margin-bottom: 4rem;
}

.category-section {
    margin-bottom: 5rem;
}

.category-title {
    font-family: 'Inter', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 2.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #ff2d8f;
    text-transform: capitalize;
    display: inline-block;
    position: relative;
}

.category-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 50px;
    height: 2px;
    background: linear-gradient(90deg, #ff2d8f, #09b9f3);
    border-radius: 2px;
}

.servers-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

@media (max-width: 900px) {
    .servers-grid {
        grid-template-columns: 1fr;
    }
}

.server-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 2.5rem;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(20px);
    cursor: pointer;
}

.server-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(135deg, #ff2d8f, #09b9f3);
}

.server-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 50px rgba(255, 45, 143, 0.2);
    border-color: rgba(255, 45, 143, 0.3);
    background: rgba(255, 255, 255, 0.08);
}

.server-name {
    font-family: 'Inter', sans-serif;
    font-size: 1.6rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0;
    margin-top: 0.5rem;
    line-height: 1.3;
}

.server-description {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 2rem;
    line-height: 1.6;
    margin-top: 0;
}

.server-details {
    display: flex;
    gap: 1rem;
    margin-bottom: 2.5rem;
    flex-wrap: wrap;
}

.server-detail {
    font-size: 0.85rem;
    background: rgba(255, 45, 143, 0.1);
    padding: 0.6rem 1.2rem;
    border-radius: 20px;
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 45, 143, 0.2);
    font-weight: 500;
    backdrop-filter: blur(10px);
}

.server-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.server-badges {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
    margin-bottom: 1rem;
    align-items: center;
    flex-wrap: wrap;
    min-height: 1.5rem;
}

.status-badge, .auth-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.3rem 0.7rem;
    border-radius: 12px;
    font-size: 0.6rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    backdrop-filter: blur(10px);
    height: 1.5rem;
    box-sizing: border-box;
    line-height: 1;
}

.auth-badge {
    background: rgba(255, 193, 7, 0.2);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.3);
    gap: 0.3rem;
}

.auth-badge .lock-icon {
    font-size: 0.7rem;
    line-height: 1;
}

.status-production {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-beta {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.status-preview {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.status-internal {
    background: rgba(168, 85, 247, 0.2);
    color: #a855f7;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

/* Modal Dialog */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.modal-overlay.show {
    display: flex;
}

.modal-content {
    background: rgba(22, 28, 42, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    padding: 0;
    position: relative;
    box-shadow: 0 25px 50px rgba(255, 45, 143, 0.3);
}

.modal-header {
    padding: 2rem 2rem 1rem 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
}

.modal-title {
    font-family: 'Inter', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.modal-category {
    color: #ff2d8f;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
}

.modal-body {
    padding: 1.5rem 2rem 2rem 2rem;
}

.modal-description {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
    margin-bottom: 2rem;
}

.modal-details {
    display: grid;
    gap: 1.5rem;
}

.modal-detail-group {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
}

.modal-detail-label {
    font-weight: 700;
    color: #09b9f3;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.modal-detail-value {
    color: rgba(255, 255, 255, 0.9);
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 0.9rem;
    background: rgba(0, 0, 0, 0.3);
    padding: 0.8rem 1rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-actions {
    padding: 1.5rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.config-field {
    margin-bottom: 1.5rem;
}

.config-field:last-child {
    margin-bottom: 0;
}

.config-field-name {
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.config-field-description {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 0.8rem;
}

.config-field-example {
    color: rgba(255, 255, 255, 0.9);
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 0.8rem;
    background: rgba(0, 0, 0, 0.3);
    padding: 0.5rem 0.8rem;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.required-field {
    border-left: 3px solid #ff2d8f;
    padding-left: 1rem;
}

.optional-field {
    border-left: 3px solid #09b9f3;
    padding-left: 1rem;
}

.modal-capabilities {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.8;
}

.modal-capabilities ul {
    margin: 0;
    padding-left: 1.2rem;
    list-style: none;
}

.modal-capabilities li {
    margin-bottom: 0.8rem;
    position: relative;
}

.modal-capabilities li::before {
    content: '✓';
    color: #10b981;
    font-weight: bold;
    position: absolute;
    left: -1.2rem;
}

/* Footer */
.footer {
    background: rgba(22, 28, 42, 0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 4rem 0 2rem 0;
    margin-top: 5rem;
}

.footer-content {
    text-align: center;
}

.footer h3 {
    font-family: 'Inter', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: #09b9f3;
    margin-bottom: 2rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 8px;
}

.footer-links a:hover {
    color: #09b9f3;
    background: rgba(9, 185, 243, 0.1);
}

.footer-info {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
    line-height: 1.8;
}

.footer-info p {
    margin-bottom: 0.5rem;
}

/* No servers state */
.no-servers {
    text-align: center;
    padding: 5rem 2rem;
    color: rgba(255, 255, 255, 0.7);
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
}

.no-servers h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #ffffff;
    font-weight: 700;
}

/* Responsive Design */
@media (max-width: 980px) {
    .hero {
        padding: 40px 0;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1.1rem;
    }

    .brain-container {
        width: 250px;
        height: 250px;
        margin-top: 0;
    }

    .features-intro {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .features-title {
        font-size: 2rem;
    }

    .servers-grid {
        grid-template-columns: 1fr;
    }

    .modal-content {
        margin: 1rem;
        max-height: 90vh;
    }

    .modal-header, .modal-body, .modal-actions {
        padding: 1.5rem;
    }

    .header-container {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-links {
        gap: 1rem;
    }

    .hero-actions {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .section-title {
        font-size: 2.2rem;
    }

    .footer-links {
        gap: 1.5rem;
    }
}

@media (max-width: 767px) {
    .hero {
        padding: 40px 0;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .brain-container {
        width: 200px;
        height: 200px;
    }

    .server-card {
        padding: 2rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 1rem;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .features-title {
        font-size: 1.5rem;
    }
}