/* ===============================================
   Zelone's Portfolio - Comprehensive Styles
   =============================================== */

/* ===== GLOBAL STYLES ===== */
:root {
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --light-color: #f8f9fa;
    --dark-color: #2c3e50;
    --muted-color: #6c757d;
    --gradient: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 8px 15px rgba(0, 0, 0, 0.15);
    --border-radius: 10px;
    --transition: all 0.3s ease;
}

* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
}

/* ===== NAVIGATION STYLES ===== */
.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--primary-color) !important;
}

.navbar-nav .nav-link {
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.navbar-nav .nav-link:hover {
    color: var(--primary-color) !important;
    transform: translateY(-1px);
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background: var(--gradient);
    transition: var(--transition);
    transform: translateX(-50%);
}

.navbar-nav .nav-link:hover::after {
    width: 80%;
}

.navbar {
    box-shadow: var(--shadow);
    background: white !important;
}

/* ===== MAIN CONTENT STYLES ===== */
.main-content {
    min-height: 60vh;
    padding: 2rem 0;
}

.content-section {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 2rem;
    transition: var(--transition);
}

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

.welcome-section {
    background: var(--gradient);
    color: white;
    text-align: center;
    padding: 3rem 2rem;
}

.welcome-section h1 {
    font-size: 2.5rem;
    font-weight: 300;
    margin-bottom: 1rem;
}

.welcome-section p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 0;
}

/* ===== REPOSITORY CARDS ===== */
.repo-card {
    transition: var(--transition);
    border: none !important;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.repo-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.repo-card .card-title {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.25rem;
}

.repo-card .card-title a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

.repo-card .card-title a:hover {
    color: var(--secondary-color);
}

.repo-card .card-subtitle {
    color: var(--muted-color);
    margin-bottom: 1rem;
}

.repo-card .lang {
    color: var(--success-color);
    font-weight: 600;
}

.repo-card .color-Zelone {
    color: var(--primary-color);
    font-weight: 600;
}
.repo-card .color-Jitesh-Jhawar {
    color: var(--secondary-color);
    font-weight: 600;
}
.repo-card .ssize {
    color: var(--muted-color);
}

.repo-card .card-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.repo-card .card-link:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* ===== BADGES AND TOPICS ===== */
.badge-topic {
    background: var(--gradient) !important;
    color: white;
    margin: 0.25rem;
    padding: 0.4rem 0.8rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 500;
    display: inline-block;
    transition: var(--transition);
}

.badge-topic:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

/* ===== LOADING SPINNER ===== */
.loading-container {
    text-align: center;
    padding: 3rem 1rem;
}

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

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

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

/* ===== ERROR STATES ===== */
.error-container {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    margin: 2rem 0;
    text-align: center;
}

.error-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.error-message {
    margin-bottom: 1rem;
}

.retry-btn {
    background: var(--gradient);
    border: none;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    transition: var(--transition);
}

.retry-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

/* ===== SEARCH FUNCTIONALITY ===== */
.search-container {
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
    position: sticky;
    top: 76px;
    z-index: 10;
}

.search-form {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.search-input {
    flex: 1;
    border-radius: 25px;
    border: 2px solid #e9ecef;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    transition: var(--transition);
}

.search-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
    outline: none;
}

.search-btn {
    border-radius: 25px;
    background: var(--gradient);
    border: none;
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    color: white;
    transition: var(--transition);
    cursor: pointer;
    white-space: nowrap;
}

.search-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.search-results {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--muted-color);
}

/* ===== FOOTER STYLES ===== */
.site-footer {
    background: var(--dark-color);
    color: white;
    padding: 3rem 0 1rem 0;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h5 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-weight: 600;
}

.footer-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: #bdc3c7;
    text-decoration: none;
    transition: var(--transition);
}

.footer-section ul li a:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-link {
    display: inline-flex;
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    color: white;
    text-align: center;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    text-decoration: none;
    transition: var(--transition);
    font-size: 1.2rem;
}

.social-link:hover {
    transform: translateY(-2px);
    background: var(--secondary-color);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.footer-bottom {
    border-top: 1px solid #34495e;
    padding-top: 1.5rem;
    text-align: center;
    color: #95a5a6;
    font-size: 0.9rem;
}

/* ===== ABOUT PAGE STYLES ===== */
.about-hero {
    background: var(--gradient);
    color: white;
    text-align: center;
    padding: 4rem 2rem;
    border-radius: var(--border-radius);
    margin-bottom: 2rem;
}

.about-hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 300;
}

.about-content {
    font-size: 1.1rem;
    line-height: 1.8;
}

/* ===== UTILITY CLASSES ===== */
.text-gradient {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
}

.btn-gradient {
    background: var(--gradient);
    border: none;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
    font-weight: 500;
}

.btn-gradient:hover {
    transform: translateY(-1px);
    color: white;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.hidden {
    display: none;
}

.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .welcome-section h1,
    .about-hero h1 {
        font-size: 2rem;
    }
    
    .content-section {
        padding: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .search-container {
        padding: 1rem;
        position: static;
    }
    
    .search-form {
        flex-direction: column;
    }
    
    .search-input {
        margin-bottom: 0.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .social-links {
        justify-content: center;
    }
    
    .repo-card {
        margin-bottom: 1rem;
    }
    
    .navbar-brand {
        font-size: 1.25rem;
    }
}

@media (max-width: 576px) {
    .welcome-section,
    .about-hero {
        padding: 2rem 1rem;
    }
    
    .welcome-section h1,
    .about-hero h1 {
        font-size: 1.75rem;
    }
    
    .content-section {
        padding: 1rem;
    }
    
    .search-container {
        padding: 0.75rem;
    }
}

/* ===== ACCESSIBILITY ===== */
.sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Focus indicators */
*:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
        --shadow-hover: 0 8px 15px rgba(0, 0, 0, 0.4);
    }
    
    .content-section,
    .repo-card,
    .search-container {
        border: 2px solid #333;
    }
}
