/* Video Toolkit Pro - Canva Style */

/* Base Styles */
.toozly-video-toolkit {
    --toozly-primary: #8550e6;
    --toozly-primary-dark: #6a3093;
    --toozly-primary-light: #a67ff3;
    --toozly-gradient: linear-gradient(135deg, #8550e6 0%, #6a3093 100%);
    --toozly-text: #333333;
    --toozly-text-light: #666666;
    --toozly-border: #e0e0e0;
    --toozly-bg: #f8f9fc;
    --toozly-card: #ffffff;
    --toozly-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --toozly-radius: 12px;
    --toozly-spacing: 24px;
    
    font-family: 'Poppins', sans-serif;
    color: var(--toozly-text);
    max-width: 600px;
    margin: 0 auto;
    background-color: var(--toozly-bg);
    border-radius: var(--toozly-radius);
    overflow: hidden;
}

/* Compact Header */
.toozly-header {
    background: var(--toozly-gradient);
    height: 35px;
    padding: 0 16px;
    color: white;
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.toozly-logo {
    display: flex;
    align-items: center;
}

.toozly-icon {
    font-size: 18px;
    margin-right: 8px;
}

.toozly-header h2 {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    line-height: 1;
}

/* Container */
.toozly-container {
    padding: 0 16px;
}

/* Card */
.toozly-card {
    background: var(--toozly-card);
    border-radius: var(--toozly-radius);
    box-shadow: var(--toozly-shadow);
    padding: 20px;
    margin-bottom: var(--toozly-spacing);
}

/* Form Groups */
.toozly-form-group {
    margin-bottom: 20px;
}

.toozly-form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 10px;
    color: var(--toozly-text);
    font-size: 14px;
}

/* Platform Selector */
.toozly-platform-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.toozly-platform-btn {
    flex: 1;
    min-width: 80px;
    max-width: 120px;
    height: 90px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--toozly-card);
    border: 2px solid var(--toozly-border);
    border-radius: var(--toozly-radius);
    padding: 12px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.toozly-platform-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.toozly-platform-btn.active {
    border-color: var(--toozly-primary);
    background-color: rgba(133, 80, 230, 0.05);
    box-shadow: 0 0 0 2px rgba(133, 80, 230, 0.2);
}

.toozly-platform-icon {
    width: 36px;
    height: 36px;
    margin-bottom: 8px;
}

.toozly-platform-btn span {
    font-size: 12px;
    font-weight: 500;
}

/* Input */
.toozly-input-wrapper {
    position: relative;
}

#video-url {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--toozly-border);
    border-radius: var(--toozly-radius);
    font-family: inherit;
    font-size: 14px;
    transition: all 0.2s ease;
    background: var(--toozly-card);
}

#video-url:focus {
    outline: none;
    border-color: var(--toozly-primary);
    box-shadow: 0 0 0 3px rgba(133, 80, 230, 0.2);
}

#video-url::placeholder {
    color: #aaa;
}

/* Button */
.toozly-button {
    display: block;
    width: 100%;
    padding: 14px 24px;
    background: var(--toozly-gradient);
    color: white;
    border: none;
    border-radius: var(--toozly-radius);
    font-family: inherit;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.toozly-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(106, 48, 147, 0.3);
}

/* Results */
.toozly-results {
    margin-bottom: var(--toozly-spacing);
}

.toozly-results.hidden {
    display: none;
}

.toozly-results h2 {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 16px;
    color: var(--toozly-text);
}

.toozly-thumbnails-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

/* Thumbnail Card */
.toozly-thumbnail-card {
    background: var(--toozly-card);
    border-radius: var(--toozly-radius);
    overflow: hidden;
    box-shadow: var(--toozly-shadow);
    transition: all 0.2s ease;
}

.toozly-thumbnail-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.toozly-thumbnail-image {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    background-color: #f0f0f0;
    overflow: hidden;
}

.toozly-thumbnail-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.toozly-thumbnail-info {
    padding: 16px;
}

.toozly-thumbnail-info h3 {
    margin: 0 0 12px;
    font-size: 14px;
    font-weight: 500;
    color: var(--toozly-text);
}

.toozly-download-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    background-color: #f0f0f0;
    border: none;
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    color: var(--toozly-text);
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
}

.toozly-download-btn:hover {
    background-color: #e5e5e5;
    transform: translateY(-1px);
}

.toozly-download-btn span {
    margin-left: 6px;
}

/* Footer */
.toozly-footer {
    text-align: center;
    padding: 12px;
    color: var(--toozly-text-light);
    font-size: 12px;
}

.toozly-footer p {
    margin: 0;
}

/* Loading Animation */
.toozly-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: toozly-spin 1s linear infinite;
    margin-right: 8px;
}

@keyframes toozly-spin {
    to {
        transform: rotate(360deg);
    }
}

/* Responsive Adjustments */
@media (max-width: 480px) {
    .toozly-platform-selector {
        gap: 8px;
    }
    
    .toozly-platform-btn {
        height: 80px;
        padding: 10px;
    }
    
    .toozly-platform-icon {
        width: 28px;
        height: 28px;
    }
    
    .toozly-card {
        padding: 16px;
    }
}

@media (max-width: 360px) {
    .toozly-platform-btn {
        flex-direction: row;
        height: auto;
        width: 100%;
        max-width: 100%;
        justify-content: flex-start;
        padding: 10px;
    }
    
    .toozly-platform-icon {
        margin-bottom: 0;
        margin-right: 10px;
    }
}
