body {
    background: linear-gradient(145deg, #f7f0fc 0%, #e9def0 100%);
    font-family: 'Nunito', sans-serif;
    min-height: 100vh;
}

.card-meme {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(4px);
    border-radius: 2.5rem;
    border: none;
    box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.25);
}

.video-preview {
    position: relative;
    width: 100%;
    max-height: 500px;
    background: #1a1a2e;
    border-radius: 1.5rem;
    overflow: hidden;
}

#memeVideo {
    width: 100%;
    height: auto;
    max-height: 500px;
    min-height: 300px;
    display: block;
    background: #1a1a2e;
}

.video-overlay-text {
    position: absolute;
    left: 0;
    right: 0;
    text-align: center;
    font-weight: bold;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.9);
    pointer-events: none;
    z-index: 5;
    padding: 15px;
    word-wrap: break-word;
}

.video-top-text {
    top: 20px;
}

.video-bottom-text {
    bottom: 20px;
}

.upload-area {
    border: 2px dashed #c4b5d4;
    border-radius: 30px;
    padding: 20px;
    text-align: center;
    background: rgba(255, 255, 255, 0.4);
    transition: 0.2s;
    cursor: pointer;
}

.upload-area:hover {
    background: rgba(255, 255, 255, 0.8);
    border-color: #7c3aed;
}

.upload-area.dragover {
    background: rgba(124, 58, 237, 0.15);
    border-color: #7c3aed;
}

.upload-label {
    cursor: pointer;
    display: block;
    width: 100%;
    padding: 20px;
    text-align: center;
}

.btn-fun {
    border-radius: 60px;
    padding: 12px 28px;
    font-weight: 700;
    letter-spacing: 0.3px;
    transition: 0.2s;
}

.btn-fun-primary {
    background: #7c3aed;
    color: white;
    border: none;
}

.btn-fun-primary:hover {
    background: #6d28d9;
    transform: translateY(-3px);
    box-shadow: 0 12px 20px -8px #7c3aed80;
    color: white;
}

.btn-fun-outline {
    background: transparent;
    border: 2px solid #7c3aed;
    color: #7c3aed;
}

.btn-fun-outline:hover {
    background: #7c3aed;
    color: white;
    transform: translateY(-3px);
}

.color-picker-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.color-picker-wrapper input[type="color"] {
    width: 50px;
    height: 50px;
    border: 2px solid #ddd;
    border-radius: 30px;
    padding: 3px;
    cursor: pointer;
    background: white;
}

.font-size-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.font-size-control input[type="range"] {
    flex: 1;
    accent-color: #7c3aed;
}

.font-size-control span {
    min-width: 40px;
    font-weight: 700;
    color: #4b3b5e;
}

.timing-control {
    display: flex;
    gap: 10px;
    align-items: center;
}

.timing-control input[type="range"] {
    flex: 1;
    accent-color: #7c3aed;
}

.share-icons i {
    font-size: 2.2rem;
    color: #4b3b5e;
    transition: 0.2s;
    cursor: pointer;
    margin: 0 6px;
}

.share-icons i:hover {
    color: #7c3aed;
    transform: scale(1.15);
}

.progress-bar-container {
    width: 100%;
    height: 6px;
    background: #e0d6eb;
    border-radius: 3px;
    overflow: hidden;
    margin-top: 10px;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #7c3aed, #a78bfa);
    width: 0%;
    transition: width 0.3s;
    border-radius: 3px;
}

.video-info {
    background: rgba(255, 255, 255, 0.5);
    border-radius: 15px;
    padding: 10px;
    margin-top: 10px;
}

.video-info small {
    color: #4b3b5e;
}

.info-box {
    background: rgba(124, 58, 237, 0.1);
    border-left: 4px solid #7c3aed;
    border-radius: 10px;
    padding: 12px 15px;
    margin-bottom: 15px;
}

.info-box i {
    color: #7c3aed;
}

.debug-info {
    background: #1a1a2e;
    color: #00ff00;
    font-family: monospace;
    font-size: 0.7rem;
    padding: 5px 10px;
    border-radius: 5px;
    margin-top: 5px;
    display: none;
    max-height: 150px;
    overflow-y: auto;
}

.debug-info.error {
    color: #ff4444;
}

.gif-preview {
    margin-top: 10px;
    display: none;
}

.gif-preview img {
    max-width: 100%;
    max-height: 200px;
    border-radius: 10px;
    border: 2px solid #7c3aed;
}

.gif-preview .gif-actions {
    margin-top: 10px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.badge-limit {
    background: #ff6b6b;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
}

.limit-notice {
    background: #fff3cd;
    border-radius: 10px;
    padding: 8px 15px;
    font-size: 0.85rem;
    color: #856404;
    margin-bottom: 15px;
}

.limit-notice i {
    margin-right: 8px;
}
