:root {
    --bg-base: #09090b;
    --bg-darker: #050507;
    
    --bg-glass: rgba(30, 20, 45, 0.5); 
    --bg-glass-hover: rgba(48, 32, 75, 0.75);
    
    --blurple: #5865F2;
    --blurple-hover: #4752C4;
    --blurple-active: #3c45a5;
    --blurple-subtle: rgba(88, 101, 242, 0.15);
    
    --text-blurple-light: #9fa8fa;
    --text-gold-light: #fbe584;
    --text-mint-light: #84fbe5;
    
    --text-main: #f2f3f5;
    --text-muted: #b5bac1;
    --text-muted-light: #dbdee1;
    
    --accent-gold: #f1c40f;
    --accent-purple: #9b84ee;
}

body {
    background: linear-gradient(180deg, var(--bg-base) 0%, #1c0e30 100%);
    background-attachment: fixed;
    
    color: var(--text-main);
    font-family: 'Poppins', sans-serif;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

.bg-dark-theme { background-color: transparent; }
.bg-darker { background-color: transparent; }

.tracking-wide { letter-spacing: 1px; }
.max-w-700 { max-width: 700px; }
.text-muted-light { color: var(--text-muted-light); }

.text-blurple-light { color: var(--text-blurple-light) !important; }
.text-gold-light { color: var(--text-gold-light) !important; }
.text-mint-light { color: var(--text-mint-light) !important; }

.icon-textbox { color: var(--text-blurple-light); }
.icon-meme { color: var(--text-mint-light); }

img.emoji {
    height: 1.2em;
    width: 1.2em;
    margin: 0 .05em 0 .1em;
    vertical-align: -0.1em;
}

.glass-nav {
    background: var(--bg-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.navbar-nav .nav-link {
    color: var(--text-muted);
    font-weight: 500;
    padding: 0.5rem 1.2rem !important;
    border-radius: 8px;
    transition: 0.2s ease;
}

.navbar-nav .nav-link:hover, 
.navbar-nav .nav-link.active {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
}

.gradient-text {
    background: linear-gradient(135deg, var(--blurple), var(--accent-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.btn-blurple {
    background-color: var(--blurple);
    color: white;
    border: none;
    font-weight: 600;
}

.btn-blurple:hover {
    background-color: var(--blurple-hover);
    color: white;
}

.btn-blurple-outline {
    background-color: transparent;
    color: var(--blurple);
    border: 2px solid var(--blurple);
    font-weight: 600;
}

.btn-blurple-outline:hover {
    background-color: var(--blurple-subtle);
    color: white;
}

.btn-blurple:active,
.btn-blurple:focus,
.btn-blurple.active {
    background-color: var(--blurple-active) !important;
    color: white !important;
    border-color: transparent !important;
}

.btn-outline-light:active,
.btn-outline-light:focus,
.btn-outline-light.active {
    background-color: rgba(255, 255, 255, 0.1) !important;
    color: white !important;
    border-color: white !important;
}

.shadow-blurple { box-shadow: 0 8px 24px rgba(88, 101, 242, 0.25); }
.shadow-mint { box-shadow: 0 8px 24px rgba(132, 251, 229, 0.15); }

.border-gold { border-top: 3px solid rgba(241, 196, 15, 0.5) !important; }

.transition-lift {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.transition-lift:hover {
    transform: translateY(-3px);
}

.transition-lift:active {
    transform: translateY(0) !important;
}

.hero-section {
    padding-top: 140px;
    padding-bottom: 80px;
}

.hero-bg-glow {
    position: absolute;
    top: 50px;
    left: 50%;
    transform: translateX(-50%);
    
    width: 80vw;
    max-width: 600px;
    height: 250px;
    border-radius: 50%;
    
    background-color: rgba(241, 196, 15, 0.15); 
    filter: blur(80px); 
    
    z-index: 0;
    pointer-events: none;
}

.hero-images {
    position: relative;
    display: inline-block;
    margin-top: 20px;
}

.hero-banner {
    width: 100%;
    max-width: 800px;
    height: 280px;
    object-fit: cover;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.05);
}

.hero-avatar {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    border: 5px solid var(--bg-base);
    position: absolute;
    bottom: -70px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-base);
}

.py-6 { padding-top: 5rem; padding-bottom: 5rem; }

.glass-card {
    background: rgba(43, 45, 49, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    transition: all 0.3s ease;
}

.glass-card:hover {
    background: var(--bg-glass-hover);
    transform: translateY(-8px);
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.glass-panel {
    background: rgba(43, 45, 49, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
}

.feature-icon-wrapper {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    font-size: 2.5rem;
}

.popular-card {
    position: relative;
    border-top: 3px solid var(--accent-gold);
    background: linear-gradient(180deg, rgba(241, 196, 15, 0.05) 0%, rgba(43, 45, 49, 0.4) 100%);
}

.popular-card::after {
    content: "USER FAVORITE";
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--accent-gold);
    color: #000;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 20px;
    letter-spacing: 0.5px;
}

.showcase-stack {
    position: relative;
    width: 100%;
    padding-bottom: 10%;
}

.showcase-img-back {
    width: 85%;
    display: block;
    margin-left: auto;
    opacity: 0.7;
    transition: all 0.4s ease;
}

.showcase-img-front {
    width: 80%;
    position: absolute;
    bottom: 0;
    left: 0;
    border: 3px solid var(--bg-darker);
    transition: all 0.4s ease;
}

.showcase-stack:hover .showcase-img-back { opacity: 1; transform: translateY(-5px); }
.showcase-stack:hover .showcase-img-front { transform: translateY(-10px) scale(1.02); }

code {
    background-color: #2b2d31;
    color: #e3e5e8;
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    font-size: 0.85em;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    border: 1px solid rgba(255,255,255,0.05);
}

.custom-list li {
    margin-bottom: 10px;
}

.hover-white:hover { color: white !important; }

@media (max-width: 992px) {
    .showcase-stack { padding-bottom: 0; margin-top: 2rem; }
    .showcase-img-back { width: 100%; margin-bottom: 1rem; opacity: 1; }
    .showcase-img-front { position: relative; width: 100%; bottom: auto; border: none; }
}

@media (max-width: 768px) {
    .hero-banner { height: 180px; }
    .hero-avatar { width: 110px; height: 110px; bottom: -55px; }
    .hero-section { padding-top: 110px; }
    h1.display-3 { font-size: 2.5rem; }
}

.automeme-anim-container {
    position: relative;
    display: block;
    overflow: hidden;
}

.automeme-img-base {
    display: block;
    width: 100%;
    height: auto;
}

.automeme-img-overlay {
    position: absolute;
    top: 8px;
    left: 8px;
    width: calc(100% - 16px);
    height: auto;
    opacity: 0;
    animation: fadeSwap 6s ease-in-out infinite;
}

@keyframes fadeSwap {
    0%, 35% { opacity: 0; }
    50%, 85% { opacity: 1; }
    100% { opacity: 0; }
}

.border-dark-subtle {
    border-color: rgba(255, 255, 255, 0.1) !important;
}