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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

header {
    text-align: center;
    margin-bottom: 40px;
}

.header-nav {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
}

.back-link, .nav-link {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 0.95rem;
    padding: 8px 16px;
    border-radius: 8px;
    transition: background 0.2s;
}

.back-link:hover, .nav-link:hover {
    background: rgba(255, 255, 255, 0.15);
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 12px;
}

.logo-icon {
    width: 48px;
    height: 48px;
    background: white;
    color: #667eea;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 24px;
}

.logo h1 {
    color: white;
    font-size: 2rem;
    font-weight: 600;
}

.tagline {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.1rem;
}

.become-partner {
    background: white;
    border-radius: 16px;
    padding: 40px;
    margin-bottom: 30px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.cta-content h2 {
    color: #1a1a2e;
    font-size: 1.8rem;
    margin-bottom: 12px;
}

.cta-content p {
    color: #666;
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto 24px;
    line-height: 1.6;
}

.cta-btn {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 14px 32px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.licensing-section {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    border-radius: 16px;
    padding: 50px 40px;
    margin-bottom: 30px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.licensing-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.15) 0%, transparent 50%);
}

.licensing-content {
    position: relative;
    z-index: 1;
}

.licensing-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.licensing-section h2 {
    color: #fff;
    font-size: 1.8rem;
    margin-bottom: 12px;
}

.licensing-subtitle {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto 28px;
    line-height: 1.6;
}

.licensing-features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    max-width: 600px;
    margin: 0 auto 28px;
    text-align: left;
}

.licensing-feature {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
}

.licensing-feature .feature-icon {
    color: #22c55e;
    font-weight: bold;
}

.licensing-cta-text {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.licensing-btn {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 14px 32px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.licensing-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

@media (max-width: 600px) {
    .licensing-section {
        padding: 30px 20px;
    }
    
    .licensing-section h2 {
        font-size: 1.4rem;
    }
    
    .licensing-features {
        grid-template-columns: 1fr;
    }
}

.filters {
    display: flex;
    gap: 16px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.search-box {
    flex: 1;
    min-width: 200px;
}

.search-box input {
    width: 100%;
    padding: 12px 16px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.category-filter select {
    padding: 12px 16px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    background: white;
    min-width: 180px;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

main {
    margin-bottom: 40px;
}

.partners-section {
    margin-bottom: 40px;
}

.section-title {
    color: white;
    font-size: 1.4rem;
    margin-bottom: 20px;
    padding-left: 4px;
}

.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.partner-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    text-align: center;
}

.partner-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.partner-card.featured {
    border: 2px solid #667eea;
    background: linear-gradient(to bottom, #f8f9ff, white);
}

.featured-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 0.75rem;
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 12px;
}

.partner-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 16px;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f0f0;
}

.partner-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.logo-placeholder {
    font-size: 32px;
    font-weight: bold;
    color: #667eea;
}

.logo-placeholder.large {
    font-size: 48px;
}

.partner-name {
    color: #1a1a2e;
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.partner-category {
    display: inline-block;
    background: #e8e8ff;
    color: #667eea;
    font-size: 0.8rem;
    padding: 4px 12px;
    border-radius: 12px;
    margin-bottom: 12px;
}

.partner-excerpt {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
}

.no-partners, .error {
    text-align: center;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.1rem;
    padding: 40px;
}

footer {
    text-align: center;
    padding: 30px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

footer p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 10px;
}

.admin-link {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 0.85rem;
}

.admin-link:hover {
    color: white;
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.modal-content {
    background: white;
    border-radius: 20px;
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    padding: 32px;
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #999;
    line-height: 1;
}

.modal-close:hover {
    color: #333;
}

.modal-partner {
    text-align: center;
}

.modal-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.modal-logo {
    width: 100px;
    height: 100px;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f0f0;
}

.modal-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.modal-title h2 {
    color: #1a1a2e;
    font-size: 1.6rem;
    margin-bottom: 8px;
}

.modal-description {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 24px;
}

.modal-description p {
    color: #444;
    line-height: 1.7;
    text-align: left;
}

.modal-links {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.partner-link {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 24px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s;
}

.partner-link:hover {
    transform: translateY(-2px);
}

.partner-link.secondary {
    background: #e8e8ff;
    color: #667eea;
}

@media (max-width: 768px) {
    .logo h1 {
        font-size: 1.5rem;
    }
    
    .become-partner {
        padding: 30px 20px;
    }
    
    .cta-content h2 {
        font-size: 1.4rem;
    }
    
    .filters {
        flex-direction: column;
    }
    
    .search-box, .category-filter select {
        width: 100%;
    }
    
    .partners-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    body {
        padding: 10px;
    }
    
    .logo-icon {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .logo h1 {
        font-size: 1.3rem;
    }
    
    .become-partner {
        padding: 24px 16px;
    }
    
    .cta-content h2 {
        font-size: 1.2rem;
    }
    
    .cta-content p {
        font-size: 0.95rem;
    }
    
    .modal-content {
        padding: 24px 16px;
    }
}
