:root {
    --primary-color: #6366f1;
    --secondary-color: #4f46e5;
    --background-dark: #0f172a;
    --surface-dark: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
}

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

body {
    font-family: system-ui, -apple-system, sans-serif;
    background: var(--background-dark);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.5;
    overflow-x: hidden;
    position: relative;
}

/* Cool animated background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 30%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(79, 70, 229, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(30, 41, 59, 0.8) 0%, var(--background-dark) 100%);
    animation: backgroundAnimation 20s ease-in-out infinite alternate;
    z-index: -1;
}

/* Grid overlay */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: -1;
}

/* Floating particles */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.particle {
    position: absolute;
    background: rgba(99, 102, 241, 0.2);
    border-radius: 50%;
    animation: float 20s infinite linear;
}

@keyframes backgroundAnimation {
    0% {
        background-position: 0% 0%;
    }
    100% {
        background-position: 100% 100%;
    }
}

@keyframes float {
    0% {
        transform: translateY(0) translateX(0) rotate(0deg);
        opacity: 0;
    }
    50% {
        opacity: 0.5;
    }
    100% {
        transform: translateY(-100vh) translateX(100vw) rotate(360deg);
        opacity: 0;
    }
}

body {
    font-family: system-ui, -apple-system, sans-serif;
    background: var(--background-dark);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.5;
    overflow-x: hidden;
}

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

.video-section {
    position: relative;
    max-width: 800px;
    margin: 2rem auto;
    background: var(--surface-dark);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.video-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
}

#ai-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-controls {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0, 0, 0, 0.5);
    padding: 0.5rem;
    border-radius: 0.5rem;
}

.button {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
}

.button:hover {
    background: var(--secondary-color);
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 100;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.terminal-modal {
    position: fixed;
    left: 0;
    right: 0;
    bottom: -100%;
    width: 100%;
    height: 80vh;
    background: var(--surface-dark);
    z-index: 101;
    transition: bottom 0.3s;
    border-radius: 1rem 1rem 0 0;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.2);
}

.terminal-modal.active {
    bottom: 0;
}

.docs-modal {
    position: fixed;
    left: -100%;
    top: 0;
    width: 400px;
    height: 100vh;
    background: var(--surface-dark);
    z-index: 101;
    transition: left 0.3s ease-in-out;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.2);
    overflow-y: auto;
}

.docs-modal.active {
    left: 0;
}

.chat-modal {
    position: fixed;
    right: -100%;
    top: 0;
    width: 400px;
    height: 100vh;
    background: var(--surface-dark);
    z-index: 101;
    transition: right 0.3s ease-in-out;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
}

.chat-modal.active {
    right: 0;
}

.modal-header {
    padding: 1rem;
    background: rgba(15, 23, 42, 0.95);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}

.terminal-window {
    height: calc(80vh - 64px);
}

.terminal,
.terminal div,
.terminal span,
.terminal .cmd,
.terminal .cmd span,
.terminal .cmd div {
    font-size: 16px !important;
    line-height: 20px !important;
}

.terminal .cmd .prompt {
    font-weight: bold;
}

.terminal {
    --size: 1.4;
    padding: 15px;
}

.docs-content {
    padding: 1.5rem;
}

.docs-section {
    margin-bottom: 2rem;
}

.docs-section h2 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.docs-section p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

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

.message {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-width: 80%;
    padding: 1rem;
    border-radius: 1rem;
    line-height: 1.5;
    animation: fadeIn 0.3s ease-in-out;
    background: var(--surface-dark);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.message.user {
    align-self: flex-end;
    background: var(--primary-color);
    border: none;
}

.message.ai {
    align-self: flex-start;
    border-bottom-left-radius: 0.25rem;
}

.message-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.9);
}

.message-header i {
    font-size: 1rem;
}

.message-header span {
    font-weight: 500;
}

.message-content {
    word-break: break-word;
    color: var(--text-primary);
}

.message.typing {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.5rem 1rem;
}

.message.typing .message-content span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    opacity: 0.7;
}

.message.typing .message-content span::after {
    content: '...';
    animation: typing 1.5s infinite;
}

@keyframes typing {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60% { content: '...'; }
    80%, 100% { content: ''; }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.chat-input input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid var(--primary-color);
}

.chat-input {
    padding: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 0.5rem;
}

.chat-input input {
    flex-grow: 1;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-size: 0.875rem;
}

.chat-input input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.15);
}

.chat-input button {
    padding: 0.75rem;
}

.volume-slider {
    width: 100px;
    height: 4px;
    -webkit-appearance: none;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
}

.header {
    text-align: center;
    margin-bottom: 3rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

.social-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.social-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 0.4rem;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.2s;
    font-weight: 500;
    font-size: 0.875rem;
}

.social-button i {
    font-size: 1rem;
}

.social-button.twitter {
    background: #1DA1F2;
}

.social-button.github {
    background: #24292F;
}

.social-button:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}

#copyNotification {
    position: fixed;
    top: -50px;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--primary-color);
    color: white;
    padding: 10px 20px;
    border-radius: 4px;
    transition: top 0.3s ease-in-out;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

#copyNotification.show {
    top: 20px;
}

#muteButton {
    pointer-events: auto !important;
    cursor: pointer;
}

/* Custom Scrollbar Styles */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--background-dark);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
    transition: background 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* Firefox Scrollbar Styles */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) var(--background-dark);
}