.eco-theme {
    --primary-color: #2ecc71;
    --primary-dark: #27ae60;
    --secondary-color: #3498db;
    --accent-color: #e67e22;
    --bg-color: #f0f6f0;
    --card-bg: #ffffff;
    --text-primary: #2c3e50;
    --text-secondary: #7f8c8d;
    --success: #2ecc71;
    --warning: #f1c40f;
    --danger: #e74c3c;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --gradient-primary: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    background-color: var(--bg-color);
}

.fiy-main {
    padding: 2rem;
    text-align: center;
    max-width: 1400px;
    margin: 0 auto;
    align-items: center;
    align-content: center;
    align-self: center;

    justify-content: center;
}

/* Hero Section */
.fiy-hero {
    text-align: center;
    align-items: center;
    justify-content: center;
    align-self: center;
    align-content: center;
    align-tracks: center;
    margin-bottom: 3rem;
    padding: 4rem 2rem;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
                url('https://images.unsplash.com/photo-1581092160562-40aa08e78837') center/cover;
    color: white;
    border-radius: 15px;
    position: relative;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.fiy-hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    font-weight: 300;
    font-family: 'Rubik Distressed';
}

.fiy-hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 2rem;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.stat-item i {
    font-size: 2rem;
    color: var(--primary-color);
}

/* Section Headers */
.section-header {
    text-align: center;
    margin-bottom: 2rem;
}

.section-header h2 {
    font-size: 2rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Repair Assistant */
.repair-assistant {
    margin-bottom: 4rem;
}

.assistant-container {
    background: var(--card-bg);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.input-wrapper {
    position: relative;
    margin-bottom: 1rem;
}

#repairQuery {
    width: 100%;
    min-height: 120px;
    padding: 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    resize: vertical;
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.3s;
}

#repairQuery:focus {
    border-color: var(--primary-color);
    outline: none;
}

.image-preview {
    margin: 1rem 0;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 12px;
    border: 2px dashed #ddd;
}

.image-preview img {
    max-width: 200px;
    max-height: 200px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.button-group {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.primary-btn, .secondary-btn {
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: transform 0.2s, background-color 0.2s;
}

.primary-btn {
    background-color: var(--primary-color);
    color: white;
}

.secondary-btn {
    background-color: #f5f5f5;
    color: var(--text-primary);
}

.primary-btn:hover, .secondary-btn:hover {
    transform: translateY(-2px);
}

.primary-btn:hover {
    background-color: var(--primary-dark);
}

/* Loading Indicator */
.loading-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    padding: 3rem;
    text-align: center;
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: var(--shadow-md);
}

.loading-indicator p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Repair Guide */
.repair-guide {
    background: #f9f9f9;
    border-radius: 12px;
    padding: 2rem;
    animation: fadeIn 0.3s ease-out;
}

.guide-header {
    background: var(--gradient-primary);
    color: white;
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 2rem;
}

.guide-header h3 {
    margin: 0;
    font-size: 1.5rem;
}

.difficulty-badge {
    padding: 0.5rem 1.5rem;
    border-radius: 25px;
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.difficulty-badge.easy { background-color: var(--success); }
.difficulty-badge.medium { background-color: var(--warning); }
.difficulty-badge.hard { background-color: var(--danger); }

.guide-content {
    display: grid;
    gap: 2rem;
}

.guide-section {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}

.guide-section:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.guide-section h4 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.guide-section i {
    color: var(--primary-color);
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    margin-right: 1rem;
    font-weight: 600;
}

.step-content {
    display: inline-block;
    vertical-align: middle;
}

.guide-section ul, .guide-section ol {
    margin: 0;
    padding: 0;
    list-style: none;
}

.guide-section li {
    margin-bottom: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    transition: background-color 0.2s;
}

.guide-section li:hover {
    background: #f0f0f0;
}

.guide-section li:last-child {
    margin-bottom: 0;
}

.guide-section li i {
    margin-right: 0.8rem;
    width: 20px;
    text-align: center;
}

.tools-section i { color: var(--primary-color); }
.safety-section i { color: var(--danger); }

.info-section {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 12px;
    margin: 2rem 0;
}

.info-section p {
    margin: 0.5rem 0;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.info-section i {
    color: var(--primary-color);
}

.warning {
    background: #fff5f5;
    color: var(--danger);
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid var(--danger);
    margin-top: 1rem;
}

.no-items {
    color: var(--text-secondary);
    font-style: italic;
    text-align: center;
    padding: 1rem;
}

/* Video Grid */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.video-card {
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s;
    cursor: pointer;
}

.video-card:hover {
    transform: translateY(-5px);
}

.video-thumbnail {
    position: relative;
    height: 215px;
    overflow: hidden;
    border-radius: 8px 8px 0 0;
    background-color: #f5f5f5;
}

.video-thumbnail iframe {
    width: 100%;
    height: 100%;
    border: none;
    position: relative;
    z-index: 1;
}

.difficulty {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    color: white;
    background-color: var(--primary-color);
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    width: auto;
    height: auto;
    pointer-events: none; /* Prevent it from blocking iframe interaction */
}

.difficulty.easy {
    background-color: #4CAF50;
}

.difficulty.medium {
    background-color: #FF9800;
}

.difficulty.hard {
    background-color: #f44336;
}

.video-info {
    padding: 1.5rem;
}

.video-info h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.2rem;
    color: var(--text-primary);
}

.video-info p {
    margin: 0 0 1rem 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.video-meta {
    display: flex;
    gap: 1rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.video-meta span {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

/* Video Links Grid */
.video-links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.video-link {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    color: var(--text-primary);
    text-decoration: none;
    box-shadow: var(--shadow-sm);
    transition: all 0.2s;
}

.video-link:hover {
    background: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.video-link i {
    color: #ff0000;
    font-size: 1.2rem;
}

.hidden {
    display: none;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .video-links-grid {
        grid-template-columns: 1fr;
    }

    .guide-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .difficulty-badge {
        align-self: center;
    }
}

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