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

@keyframes shimmer {
    0% {
        opacity: 0.3;
    }
    50% {
        opacity: 0.5;
    }
    100% {
        opacity: 0.3;
    }
}

body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow: hidden;
    background: #0a0a0a;
    font-family: system-ui, -apple-system, sans-serif;
    color: #ffffff;
}

.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    background: radial-gradient(2px 2px at 20px 30px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 40px 70px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 50px 160px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 90px 40px, #ffffff, rgba(0, 0, 0, 0)),
    radial-gradient(2px 2px at 130px 80px, #ffffff, rgba(0, 0, 0, 0));
    background-repeat: repeat;
    animation: shimmer 4s infinite;
}

.gradient-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #1a1a1a, #2a0a2a, #0a1a2a);
    background-size: 400% 400%;
    animation: gradient 15s ease infinite;
    opacity: 0.7;
}

.container {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100vh;
    z-index: 1;
}

.header {
    height: 20vh;
    padding: 2rem;
    box-sizing: border-box;
    text-align: center;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.header h1 {
    margin: 0;
    font-size: 2.5rem;
    background: linear-gradient(45deg, #fff, #a8a8a8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.header p {
    color: #a8a8a8;
    margin-top: 1rem;
}

.content {
    display: flex;
    height: 80vh;
}

#canvasContainer {
    width: 50%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
    border-left: 1px solid rgba(255, 255, 255, 0.1);
}

#ComposeTarget {
    width: 100%;
    height: 100%;
}

#htmlContent {
    width: 50%;
    height: 100%;
    overflow-y: auto;
    padding: 2rem;
    box-sizing: border-box;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
}

.section {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.section:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.2);
}

.section h2 {
    margin: 0 0 1rem 0;
    font-size: 1.5rem;
    background: linear-gradient(45deg, #fff, #a8a8a8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section p {
    color: #a8a8a8;
    line-height: 1.6;
    margin: 0;
}

.tags {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.tag {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.875rem;
    color: #a8a8a8;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Custom scrollbar */
#htmlContent::-webkit-scrollbar {
    width: 8px;
}

#htmlContent::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

#htmlContent::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

#htmlContent::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.preview-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.preview-container:hover .preview-overlay {
    opacity: 1;
}