:root {
    --primary-color: #6d00ff;
    --secondary-color: #00c4ff;
    --accent-color: #ff00ea;
    --dark-color: #0e0b16;
    --light-color: #f1f1f6;
    --gradient-bg: linear-gradient(135deg, #0a0426 0%, #1a0b2e 50%, #210535 100%);
    --symbol-glow: 0 0 15px rgba(109, 0, 255, 0.7);
    --card-bg: rgba(20, 10, 40, 0.7);
    --text-shadow: 0 0 5px rgba(109, 0, 255, 0.7);
}

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

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--light-color);
    background-color: var(--dark-color);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
    z-index: 10;
}

/* Cosmic Background */
.cosmic-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    background-image: url('b9b88f7d-cafd-4a9c-b010-c46b95dac314.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 4, 38, 0.7);
    z-index: 2;
}

.stars {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
}

.star {
    position: absolute;
    background-color: white;
    border-radius: 50%;
    opacity: 0.3;
    animation: twinkle 5s infinite ease-in-out;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.8; }
}

/* Header */
header {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
}

h1 {
    font-family: 'Space Mono', monospace;
    font-size: 4rem;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: var(--text-shadow);
    position: relative;
    display: inline-block;
}

h1 span {
    display: block;
    font-size: 1.2rem;
    letter-spacing: 1px;
    margin-top: 0.5rem;
    opacity: 0.8;
}

.subtitle {
    font-size: 1.2rem;
    color: var(--secondary-color);
    margin-bottom: 2rem;
    letter-spacing: 1px;
}

.audio-controls {
    margin-top: 1rem;
}

.music-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    letter-spacing: 1px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.music-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
}

/* Intro */
.intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 3rem;
    font-size: 1.2rem;
    line-height: 1.8;
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Symbol Display */
.symbols-container {
    margin-bottom: 4rem;
}

.symbol-display {
    background: var(--card-bg);
    padding: 3rem 2rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.symbol-text {
    font-family: 'Space Mono', monospace;
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--secondary-color);
    text-shadow: var(--symbol-glow);
    letter-spacing: 2px;
}

.symbol-interpretation {
    font-size: 1.2rem;
    line-height: 1.6;
    max-width: 800px;
    opacity: 0.9;
}

.symbol-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

button {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 30px;
    cursor: pointer;
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    letter-spacing: 1px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
}

button:active {
    transform: translateY(1px);
}

/* LLML Section */
.llml-section {
    margin-bottom: 4rem;
}

h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--secondary-color);
    letter-spacing: 1px;
    position: relative;
}

h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    border-radius: 3px;
}

.llml-content {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.llml-content > p {
    margin-bottom: 2rem;
    text-align: center;
    font-size: 1.1rem;
}

.llml-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
}

.feature {
    background: rgba(20, 10, 40, 0.5);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.feature:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    border-color: var(--primary-color);
}

.feature h3 {
    color: var(--accent-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

/* Symbol Explorer */
.symbol-explorer {
    margin-bottom: 4rem;
}

.series-selector {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.series-btn {
    background: rgba(20, 10, 40, 0.5);
    color: var(--light-color);
    padding: 0.8rem 1.5rem;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
}

.series-btn:hover, .series-btn.active {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
}

.symbol-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.symbol-item {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.symbol-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    border-color: var(--primary-color);
}

.symbol-item-text {
    font-family: 'Space Mono', monospace;
    font-size: 1.3rem;
    color: var(--secondary-color);
    text-shadow: var(--symbol-glow);
    margin-bottom: 0.5rem;
}

.symbol-item-name {
    font-size: 0.9rem;
    opacity: 0.8;
}

.symbol-detail {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 2rem;
}

.detail-symbol {
    font-family: 'Space Mono', monospace;
    font-size: 2rem;
    color: var(--secondary-color);
    text-shadow: var(--symbol-glow);
    text-align: center;
    margin-bottom: 1.5rem;
}

.detail-interpretation, .detail-implication {
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.detail-interpretation::before {
    content: 'Interpretation:';
    display: block;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
    font-weight: bold;
}

.detail-implication::before {
    content: 'Implication:';
    display: block;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
    font-weight: bold;
}

/* Interactive Builder */
.interactive-builder {
    margin-bottom: 4rem;
}

.builder-interface {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.symbol-palettes {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.palette-category h4 {
    font-size: 1.1rem;
    margin-bottom: 0.8rem;
    color: var(--accent-color);
    letter-spacing: 1px;
}

.palette-symbols {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.symbol-btn {
    background: rgba(109, 0, 255, 0.1);
    color: var(--secondary-color);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.5rem 0.8rem;
    border-radius: 4px;
    font-family: 'Space Mono', monospace;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 40px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.symbol-btn:hover {
    background: rgba(109, 0, 255, 0.2);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.expression-composer {
    margin-top: 2rem;
}

.composer-input {
    margin-bottom: 1.5rem;
}

.expression-input {
    width: 100%;
    padding: 1rem;
    background: rgba(10, 5, 20, 0.8);
    color: var(--secondary-color);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    font-family: 'Space Mono', monospace;
    font-size: 1.5rem;
    min-height: 80px;
    text-align: center;
    outline: none;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    letter-spacing: 1px;
    text-shadow: var(--symbol-glow);
}

.expression-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(109, 0, 255, 0.3);
}

.expression-input[placeholder]:empty:before {
    content: attr(placeholder);
    color: rgba(255, 255, 255, 0.4);
}

.composer-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.custom-interpretation {
    background: rgba(10, 5, 20, 0.6);
    padding: 1.5rem;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    line-height: 1.6;
    min-height: 100px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Collaborative Space */
.collaborative-space {
    margin-bottom: 4rem;
}

.collaboration-container {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.shared-symbols {
    margin-bottom: 2rem;
}

.community-symbols-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-height: 300px;
    overflow-y: auto;
    padding-right: 10px;
}

.community-symbol-item {
    background: rgba(10, 5, 20, 0.6);
    padding: 1.5rem;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.community-symbol-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    border-color: var(--primary-color);
}

.symbol-sentence {
    font-family: 'Space Mono', monospace;
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--secondary-color);
    text-shadow: var(--symbol-glow);
    word-wrap: break-word;
}

.interpretations-list {
    margin-bottom: 1rem;
}

.symbol-author {
    font-size: 0.9rem;
    text-align: right;
    color: var(--accent-color);
    font-style: italic;
}

.symbol-input-area {
    margin-top: 2rem;
}

.symbol-reactions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
    justify-content: flex-end;
}

.reaction-btn {
    background: rgba(109, 0, 255, 0.1);
    color: var(--secondary-color);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.reaction-btn:hover {
    background: rgba(109, 0, 255, 0.2);
    transform: translateY(-2px);
}

.reaction-count {
    margin-left: 0.3rem;
}

/* Footer */
footer {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
    max-width: 800px;
    margin: 0 auto;
}

.call-to-action {
    margin-top: 1.5rem;
    font-weight: bold;
    color: var(--accent-color);
    font-size: 1.2rem;
}

/* Animations */
.animate-in {
    animation: fadeIn 0.5s ease-in-out;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    h1 {
        font-size: 3rem;
    }
    
    h1 span {
        font-size: 1rem;
    }
    
    .symbol-text {
        font-size: 1.8rem;
    }
    
    .symbol-controls {
        flex-direction: column;
    }
    
    .series-selector {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2.5rem;
    }
    
    .container {
        padding: 1rem;
    }
    
    .symbol-display {
        padding: 2rem 1rem;
    }
    
    button {
        padding: 0.7rem 1.2rem;
    }
    
    .composer-controls {
        flex-direction: column;
    }
    
    .symbol-palettes {
        grid-template-columns: 1fr;
    }
}