/* --- V4.2: ENHANCED MOBILE RESPONSIVENESS --- */

/* 1. VARIABLES & GLOBAL RESETS */
:root {
    --bg-color: #0d0c12;
    --platform-bg-color: #00000021;
    --card-bg-color: rgba(5, 4, 8, 0.5);
    --accent-purple: #8A2BE2;
    --glow-color: rgba(138, 43, 226, 0.25);
    --text-primary: #f0f0f5;
    --text-secondary: #a0a0b0;
    --border-color: rgba(255, 255, 255, 0.08);
    --font-family: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    line-height: 1.7;
    background-color: var(--bg-color);
    color: var(--text-primary);
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

/* 2. BACKGROUND & LAYOUT */
.background-glow {
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at center, var(--glow-color) 0%, transparent 40%);
    animation: rotateGlow 25s linear infinite;
    z-index: -1;
}

@keyframes rotateGlow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

main > section {
    margin-bottom: 3rem;
    padding: 0 20px;
}

/* 3. HEADER & TYPOGRAPHY */
header {
    padding: 1rem 20px;
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(13, 12, 18, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.logo img {
    height: 40px;
}

.nav-link {
    color: var(--text-secondary);
    padding: 0.5rem;
    margin-right: 1rem;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: var(--text-primary);
}

h1, h2 {
    font-weight: 700;
    letter-spacing: -1px;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: #fff;
}

p {
    color: var(--text-secondary);
}

/* 4. BUTTONS */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}
.btn-primary {
    background-color: var(--accent-purple);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(138, 43, 226, 0.3);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(138, 43, 226, 0.5);
}

/* 5. HERO SECTION */
#hero {
    padding: 100px 20px;
    text-align: center;
}
#hero h1 {
    font-size: 4.5rem;
    line-height: 1.1;
    color: #fff;
    margin-bottom: 1.5rem;
}
#hero .subtitle {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
}

/* 6. PLATFORM & CARD STYLES */
.platform {
    background: var(--platform-bg-color);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 4rem;
    text-align: center;
}

.platform-subtitle {
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 4rem;
}

.card, .tool-card {
    background: var(--card-bg-color);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2.5rem;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: all 0.3s ease;
}

.card:hover, .tool-card:hover {
    border-color: var(--glow-color);
    transform: translateY(-4px);
    background: rgba(22, 21, 28, 0.75);
}

#private-apps .card, #build-request .card {
    padding: 3rem 4rem;
    text-align: center;
}
#build-request .card p {
    margin-bottom: 0;
}

/* 7. TOOL GRID & ICONS */
.tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 4rem;
}
.tool-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.tool-icon {
    margin-bottom: 1.5rem;
    background: rgba(138, 43, 226, 0.1);
    border-radius: 50%;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.tool-icon svg {
    width: 32px;
    height: 32px;
    stroke: var(--accent-purple);
    transition: stroke 0.3s ease;
}
.tool-card:hover .tool-icon svg {
    stroke: #fff;
}
.tool-card h3 {
    font-size: 1.3rem;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}
.tool-card p {
    font-size: 1rem;
    margin: 0;
}
.tool-grid-small {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 4rem;
    max-width: 720px;
    margin-left: auto;
    margin-right: auto;
}

/* 8. CUSTOM SHOWCASE STYLES */
.showcase-feature {
    display: grid;
    grid-template-columns: 2fr 1fr;
    align-items: center;
    gap: 3rem;
    text-align: left;
    margin-bottom: 4rem;
}
.feature-text h3 {
    font-size: 2rem;
    color: #fff;
    margin-bottom: 1rem;
}
.feature-text p {
    text-align: left;
    margin: 0 0 1.5rem 0;
    max-width: none;
}
.feature-text ul {
    list-style: none;
    padding-left: 0;
}
.feature-text li {
    padding-left: 2rem;
    position: relative;
    margin-bottom: 0.5rem;
}
.feature-text li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--accent-purple);
    font-weight: bold;
}
.feature-icon {
    display: flex;
    justify-content: center;
    align-items: center;
}
.feature-icon svg {
    width: 120px;
    height: 120px;
    fill: none;
    stroke: rgba(138, 43, 226, 0.5);
    stroke-width: 1.5;
    transition: all 0.3s ease;
}
.showcase-feature:hover .feature-icon svg {
    stroke: var(--accent-purple);
    transform: scale(1.1);
}
.showcase-group {
    margin-top: 4rem;
    padding-top: 4rem;
    border-top: 1px solid var(--border-color);
}
.showcase-group h3 {
    font-size: 2rem;
    color: #fff;
    margin-bottom: 1rem;
}
.showcase-group p {
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* 9. RESPONSIVE DESIGN (MOBILE REVISIONS) */
@media (max-width: 768px) {
    /* General Typography & Spacing */
    body {
        line-height: 1.8; /* Improves readability of paragraphs */
    }

    #hero {
        padding: 60px 20px; /* Reduced vertical padding */
    }

    #hero h1 {
        font-size: 2.8rem; /* Significantly smaller H1 for mobile */
        line-height: 1.2;
    }
    
    #hero .subtitle {
        font-size: 1.1rem; /* Slightly smaller subtitle */
    }
    
    h2 {
        font-size: 2rem; /* Smaller section titles */
    }

    /* Platform & Card Padding */
    .platform {
        padding: 2.5rem 1.5rem; /* Reduced padding for platforms */
    }

    .card, .tool-card {
        padding: 2rem; /* Reduced padding for all cards */
    }

    #private-apps .card, #build-request .card {
        padding: 2.5rem 2rem; /* Specific reduction for standalone cards */
    }

    /* Custom Showcase Adjustments */
    .showcase-feature {
        grid-template-columns: 1fr; /* Stack columns */
        text-align: center;
    }

    .feature-text p, .feature-text ul {
        text-align: center;
        margin-left: auto;
        margin-right: auto;
    }

    .feature-text ul {
        display: inline-block;
        text-align: left; /* Keep list items aligned left for readability */
    }
    
    .feature-text h3 {
        font-size: 1.75rem; /* Smaller heading for feature block */
    }

    .feature-icon {
        margin-top: 2rem;
    }
    
    .feature-icon svg {
        width: 90px;  /* Resized icon for mobile */
        height: 90px;
    }
}

/* 10. FOOTER */
footer {
    padding: 4rem 20px 2rem 20px;
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

footer a:hover {
    color: var(--accent-purple);
}