@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;700&display=swap');

:root {
    --primary: #007aff;
    --background-light: rgba(248, 248, 248, 0.5);
    --background-dark: rgba(18, 18, 18, 0.8);
    --text-light: #333;
    --text-dark: #f1f1f1;
    --shadow: rgba(0, 0, 0, 0.1);
}

/* Global Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Body with Gradient */
body {
    display: flex;
    min-height: 100vh;
    justify-content: center;
    align-items: center;
    text-align: center;
    background: black;
    transition: background 1s ease-in-out;
    margin: 0;
    font-family: 'Inter', sans-serif;
}

/* Loaded Background */
body.loaded {
    background: linear-gradient(120deg, rgba(114, 0, 0, 0.5), rgba(117, 53, 1, 0.5), rgba(0, 52, 78, 0.5));
}

/* Splash Screen */
#splash-screen {
    position: fixed;
    width: 100%;
    height: 100%;
    background: black;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 1s ease-in-out;
}

/* GPTBot Logo */
#logo {
    width: 250px;
    height: auto;
    opacity: 0;
    animation: pulseFade 1.5s infinite alternate;
    margin-bottom: 10px;
}

@keyframes pulseFade {
    0% { transform: scale(0.9); opacity: 0.8; }
    50% { transform: scale(1); opacity: 1; }
    100% { transform: scale(1.1); opacity: 0.9; }
}

/* Main Content */
.container {
    display: none;
    background: var(--background-light);
    padding: 20px;
    width: 90%;
    max-width: 600px;
    border-radius: 20px;
    box-shadow: 0px 10px 30px var(--shadow);
    transition: background 0.3s ease-in-out;
}

/* Dark Mode */
.dark-mode {
    background: var(--background-dark);
    color: var(--text-dark);
    transition: background 0.5s ease-in-out, color 0.5s ease-in-out;
}

/* Dark Mode Container */
.dark-mode .container {
    background: rgba(40, 40, 40, 0.8);
}

/* Button Ripple Effect */
button {
    background: var(--primary);
    color: white;
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    cursor: pointer;
    transition: 0.3s;
    position: relative;
    overflow: hidden;
    display: block;
    margin: 10px auto;
}

button:after {
    content: "";
    position: absolute;
    background: rgba(255, 255, 255, 0.3);
    width: 100px;
    height: 100px;
    transform: scale(0);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform-origin: center;
    transition: transform 0.5s ease-out, opacity 0.5s ease-out;
}

button:active:after {
    transform: scale(4);
    opacity: 0;
}

button:hover {
    opacity: 0.9;
}

/* Search Input */
input[type="text"] {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    border-radius: 10px;
    border: 1px solid #ccc;
    outline: none;
}

/* Command List */
ul {
    list-style: none;
    padding: 0;
}

li {
    padding: 10px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    transition: 0.3s;
}

li:hover {
    background: rgba(0, 0, 0, 0.05);
}

/* Dark Mode for List */
.dark-mode li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.dark-mode li:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* Responsive Command List */
#command-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    list-style: none;
    padding: 0;
    max-width: 1000px;
    margin: auto;
    padding: 10px;
}

/* Command List Items */
#command-list li {
    background: rgba(255, 255, 255, 0.1);
    padding: 10px;
    border-radius: 6px;
    text-align: center;
    font-size: 14px;
    transition: background 0.3s, transform 0.2s ease-in-out;
    cursor: pointer;
}

#command-list li:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        width: 95%;
        max-width: 90%;
        padding: 15px;
    }

    #command-list {
        grid-template-columns: 1fr;
    }

    .btn {
        font-size: 12px;
        padding: 8px;
    }

    #logo {
        width: 200px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 10px;
        max-width: 100%;
    }

    button {
        padding: 10px;
        font-size: 14px;
    }

    #command-list {
        grid-template-columns: 1fr;
    }
}

footer {
    position: fixed;
    bottom: 10px;
    left: 10px;
    font-size: 14px;
    color: white;
    opacity: 0.5;
    pointer-events: none;
}

/* Invite Bot Button */
#invite-bot {
    background: #7289DA;
    color: white;
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 170px;
    height: 44px;
    font-size: 16px;
    cursor: pointer;
    transition: 0.3s;
    margin-top: 15px;
}

#invite-bot img {
    width: 24px;
    height: auto;
    margin: 10px auto;
}

#invite-bot:hover {
    background: #5b6eae;
}

/* Expanded Command Style */
.command-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 10px;
    border-radius: 6px;
    text-align: center;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.3s, transform 0.2s ease-in-out, max-height 0.4s ease-in-out, padding 0.4s ease-in-out;
    overflow: hidden;
    max-height: 40px;
    line-height: 40px;
    white-space: nowrap;
}

.command-item:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

/* Expanded State */
.command-item.expanded {
    max-height: 150px;
    white-space: normal;
    padding: 15px;
    font-size: 16px;
    line-height: 24px;
}

img {
    pointer-events: none;
    -webkit-user-drag: none;
}

img::after {
    content: "© EternalAI";
    position: absolute;
    bottom: 10px;
    right: 10px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 20px;
}

.image-container {
    position: relative;
    display: inline-block;
}

.image-container img {
    display: block;
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    pointer-events: none; /* Prevent interaction */
}