/* Define the color palette */
:root {
    --secondary-color: #9370DB; /* MediumPurple */
    --text-color: #E0E0E0;
    --text-color-light: #B0B0B0;
    --card-background: #272744;
    --card-border-color: #3B3B6B;
    --primary-color: #1A1A2E;
    --hover-color: #7B68EE; /* Darker shade of MediumPurple */
}

/* General Body Styles */
body {
    background-color: var(--primary-color);
    color: var(--text-color);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    margin: 0;
    line-height: 1.6;
}

/* Header and Navigation */
header {
    background-color: var(--primary-color);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--card-border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.logo-area h1 {
    margin: 0;
    font-size: 1.8rem;
}

.logo-area a {
    text-decoration: none;
    color: var(--secondary-color);
    font-weight: bold;
}

nav ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

nav a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    padding: 0.5rem 0;
    position: relative;
    transition: color 0.3s ease;
}

nav a:hover {
    color: var(--secondary-color);
}

nav a::after {
    content: '';
    position: absolute;
    width: 100%;
    transform: scaleX(0);
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--secondary-color);
    transform-origin: bottom right;
    transition: transform 0.25s ease-out;
}

nav a:hover::after {
    transform: scaleX(1);
    transform-origin: bottom left;
}

/* Main Content */
main {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

section {
    margin-bottom: 4rem;
}

section h2 {
    text-align: center;
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 2.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--card-border-color);
    display: inline-block;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.product {
    background-color: var(--card-background);
    border: 1px solid var(--card-border-color);
    border-radius: 8px;
    padding: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.product:hover {
    transform: translateY(-8px);
    border-color: var(--secondary-color);
    box-shadow: 0 8px 25px rgba(147, 112, 219, 0.2);
}

.product h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: var(--text-color);
    font-size: 1.5rem;
}

.product p {
    margin: 0;
    color: var(--text-color-light);
}

/* Contact Section */
#contact {
    text-align: center;
    background-color: var(--card-background);
    padding: 3rem 2rem;
    border-radius: 8px;
    border: 1px solid var(--card-border-color);
}

#contact p {
    font-size: 1.2rem;
    margin: 0;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    margin-top: 2rem;
    border-top: 1px solid var(--card-border-color);
    color: var(--text-color-light);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 1rem;
    }

    main {
        padding: 1rem;
    }

    section h2 {
        font-size: 2rem;
    }
}