:root {
    --bg-color: #0f0f13;
    --card-bg: #1a1a24;
    --primary: #ff4b8b;
    --primary-hover: #e03e76;
    --text-main: #ffffff;
    --text-muted: #a0a0b0;
    --glass: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0 3rem;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(45deg, #ff4b8b, #ff9a8b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--card-bg);
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    position: relative;
    border: 1px solid var(--glass-border);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(255, 75, 139, 0.2);
}

.card-img {
    width: 100%;
    height: 300px;
    object-fit: cover;
}

.card-content {
    padding: 1.5rem;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.card-subtitle {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 5px;
}

.online {
    background-color: #4caf50;
    box-shadow: 0 0 10px #4caf50;
}

.offline {
    background-color: #f44336;
}

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

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--card-bg);
    width: 90%;
    max-width: 900px;
    height: 80vh;
    border-radius: 20px;
    display: flex;
    overflow: hidden;
    border: 1px solid var(--glass-border);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.modal-left {
    width: 40%;
    background-size: cover;
    background-position: center;
    position: relative;
}

.modal-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
}

.modal-right {
    width: 60%;
    display: flex;
    flex-direction: column;
}

.chat-header {
    padding: 1.5rem;
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-messages {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.message {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 12px;
    font-size: 0.95rem;
    line-height: 1.4;
}

.message.user {
    align-self: flex-end;
    background: var(--primary);
    color: white;
    border-bottom-right-radius: 2px;
}

.message.bot {
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-main);
    border-bottom-left-radius: 2px;
}

.chat-input-area {
    padding: 1.5rem;
    border-top: 1px solid var(--glass-border);
    display: flex;
    gap: 1rem;
}

.chat-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    padding: 12px;
    border-radius: 8px;
    color: white;
    outline: none;
}

.btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s;
}

.btn:hover {
    background: var(--primary-hover);
}

.btn:disabled {
    background: #555;
    cursor: not-allowed;
}

.limit-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    z-index: 10;
}

.btn-small {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    padding: 5px 12px;
    border-radius: 15px;
    text-decoration: none;
    font-size: 0.85rem;
    transition: all 0.2s;
    cursor: pointer;
}

.btn-small:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .modal-content {
        flex-direction: column;
        height: 90vh;
    }

    .modal-left {
        width: 100%;
        height: 150px;
    }

    .modal-right {
        width: 100%;
        height: calc(100% - 150px);
    }
}