/* ===== BASE STYLES ===== */
:root {
    --primary-color: #6366f1;
    --secondary-color: #8b5cf6;
    --accent-color: #a855f7;
    --text-dark: #f8fafc;
    --text-light: #cbd5e1;
    --bg-light: #0f172a;
    --bg-white: #1e293b;
    --bg-card: #334155;
    --border-color: #475569;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.3);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.4);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.5);
    --border-radius: 0.75rem;
    --gradient-primary: linear-gradient(135deg, #1e293b 0%, #334155 50%, #475569 100%);
    --gradient-hero: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
}

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

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light);
}

.main-content {
    padding-top: 80px;
    /* Account for fixed navbar */
}

/* ===== TYPOGRAPHY ===== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-dark);
}

.display-4 {
    font-weight: 700;
}

.lead {
    color: var(--text-light);
    font-size: 1.125rem;
}

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

.navbar-nav .nav-link {
    font-weight: 500;
    transition: color 0.3s ease;
}

.navbar-nav .nav-link:hover {
    color: var(--accent-color) !important;
}

/* ===== HERO SECTION ===== */
.hero-section {
    background: var(--gradient-hero);
    color: white;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.1;
}

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

.profile-image {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    border: 6px solid rgba(255, 255, 255, 0.2);
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s ease;
}

.profile-image:hover {
    transform: scale(1.05);
}

.profile-image-centered {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    border: 6px solid rgba(255, 255, 255, 0.2);
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s ease;
    display: block;
    margin: 0 auto;
}

.profile-image-centered:hover {
    transform: scale(1.05);
}

/* ===== MODAL STYLING ===== */
.modal-info-card {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
}

.modal-badge-card {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) !important;
    border: none !important;
    color: white !important;
}

.modal-badge-card .card-title {
    color: white !important;
}

.modal-badge-image {
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.modal-badge-image:hover {
    transform: scale(1.05);
}

.modal-card-title {
    color: #1e293b !important;
    font-weight: 600;
}

.modal-card-text {
    color: #64748b !important;
}

.modal-credential-code {
    background: #f1f5f9 !important;
    color: #1e293b !important;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.8em;
}

.modal-label {
    color: #64748b !important;
    font-weight: 500;
}

.modal-value {
    color: #1e293b !important;
    font-weight: 500;
}

.modal-content .lead {
    color: #334155 !important;
    font-weight: 400;
    line-height: 1.6;
}

.modal-content p {
    color: #334155 !important;
}

.modal-content h5 {
    color: #1e293b !important;
    font-weight: 600;
}

/* ===== SOCIAL LINKS ===== */
.social-links {
    margin-top: 1rem;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: white;
    font-size: 1.25rem;
    text-decoration: none;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.social-link:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
    color: white;
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Hero Skills Badges */
.hero-divider {
    border: 0;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.3), transparent);
    margin: 1.5rem 0;
}

.hero-skills-container {
    display: flex;
    justify-content: center;
}

.hero-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    max-width: 800px;
}

.skill-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.625rem;
    border-radius: 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    height: 28px;
    min-height: 28px;
    line-height: 1;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.skill-icon {
    font-size: 0.875rem;
    opacity: 0.9;
}

.skill-badge.skill-expert {
    background: rgba(34, 197, 94, 0.7);
    color: white;
}

.skill-badge.skill-advanced {
    background: rgba(59, 130, 246, 0.7);
    color: white;
}

.skill-badge.skill-intermediate {
    background: rgba(168, 85, 247, 0.7);
    color: white;
}

.skill-badge.skill-beginner {
    background: rgba(148, 163, 184, 0.7);
    color: white;
}

.skill-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* ===== SECTIONS ===== */
.section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    color: var(--primary-color);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
}

/* ===== CARDS ===== */
.card {
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    background: var(--bg-card);
}

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

.card-header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    border-radius: var(--border-radius) var(--border-radius) 0 0 !important;
}

/* ===== EXPERIENCE CARDS ===== */
.experience-card {
    border-left: 4px solid var(--primary-color);
    margin-bottom: 2rem;
}

.experience-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.experience-title {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
}

.experience-company {
    color: var(--primary-color);
    font-weight: 500;
}

.experience-duration {
    background: var(--bg-white);
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    color: var(--text-light);
    white-space: nowrap;
}

.experience-technologies {
    margin-top: 1rem;
}

/* Fix experience card text readability - MAXIMUM SPECIFICITY */
.section.bg-white .card.experience-card p.text-muted,
.section.bg-white .card.experience-card .text-muted {
    color: #94a3b8 !important;
}

.section.bg-white .card.experience-card p.mb-3,
.section.bg-white .card.experience-card p {
    color: #e2e8f0 !important;
}

.section.bg-white .card.experience-card .experience-title,
.section.bg-white .card.experience-card h4 {
    color: #f8fafc !important;
}

/* Fix education card text readability - SAME STYLING AS EXPERIENCE */
.section .card.education-card p.text-muted,
.section .card.education-card .text-muted {
    color: #94a3b8 !important;
}

.section .card.education-card p.mb-3,
.section .card.education-card p {
    color: #e2e8f0 !important;
}

.section .card.education-card .education-title,
.section .card.education-card h4 {
    color: #f8fafc !important;
}

.section .card.education-card .education-institution,
.section .card.education-card h5 {
    color: #a855f7 !important;
}

.section .card.education-card .education-date {
    color: #94a3b8 !important;
}

.section .card.education-card .education-gpa,
.section .card.education-card .education-honors {
    color: #cbd5e1 !important;
}

/* Education layout styling */
.education-content-wrapper {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.education-text-content {
    flex: 1;
}

/* Education image styling */
.education-image-container {
    flex-shrink: 0;
}

.education-image {
    position: relative;
    width: 100px;
    height: 100px;
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.education-image:hover {
    transform: scale(1.05);
}

.education-degree-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.education-image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    color: white;
    font-size: 1.2rem;
}

.education-image:hover .education-image-overlay {
    opacity: 1;
}

/* Responsive design for education cards */
@media (max-width: 768px) {
    .education-content-wrapper {
        flex-direction: column;
        gap: 1rem;
    }

    .education-image-container {
        align-self: center;
    }

    /* Responsive skills layout */
    .hero-skills {
        gap: 0.375rem;
        max-width: none;
    }

    .skill-badge {
        font-size: 0.7rem;
        padding: 0.2rem 0.5rem;
        gap: 0.25rem;
        height: 26px;
        min-height: 26px;
    }
}

.bg-white .section-title {
    color: #1e293b !important;
}

.tech-tag {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    margin: 0.25rem 0.25rem 0.25rem 0;
}

/* ===== SKILLS SECTION ===== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.skill-category {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease;
}

.skill-category:hover {
    transform: translateY(-3px);
}

.skill-category h4 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.skill-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.skill-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.skill-name {
    font-weight: 500;
}

.skill-level {
    font-size: 0.875rem;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-weight: 500;
}

.skill-level.expert {
    background: #dcfce7;
    color: #166534;
}

.skill-level.advanced {
    background: #dbeafe;
    color: #1d4ed8;
}

.skill-level.intermediate {
    background: #fef3c7;
    color: #92400e;
}

.skill-level.beginner {
    background: #fee2e2;
    color: #991b1b;
}

/* ===== CERTIFICATION GALLERY ===== */
.certifications-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.certification-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.certification-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-lg);
}

.certification-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
}

.certification-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.certification-card:hover .certification-image img {
    transform: scale(1.1);
}

.certification-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
}

.certification-card:hover .certification-overlay {
    opacity: 0.9;
}

.certification-content {
    padding: 1.5rem;
}

.certification-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
    font-size: 1.1rem;
    line-height: 1.3;
}

.certification-org {
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.certification-date {
    color: var(--text-light);
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.certification-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
}

.certification-status {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.status-active {
    background: #dcfce7;
    color: #166534;
}

.status-expired {
    background: #fee2e2;
    color: #991b1b;
}

/* Badge Corner Design */
.certification-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
}

.badge-corner {
    width: 50px;
    height: 50px;
    object-fit: contain;
    border-radius: 50%;
    border: 3px solid var(--bg-white);
    background: var(--bg-white);
    padding: 4px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.certification-card:hover .badge-corner {
    transform: scale(1.15);
    border-color: var(--primary-color);
    box-shadow: 0 6px 12px rgba(37, 99, 235, 0.3);
}

/* Legacy badge thumbnail for footer (if needed) */
.badge-thumbnail {
    width: 40px;
    height: 40px;
    object-fit: contain;
    border-radius: 6px;
    border: 2px solid var(--border-color);
    background: var(--bg-white);
    padding: 4px;
    transition: transform 0.2s ease;
}

.certification-card:hover .badge-thumbnail {
    transform: scale(1.1);
    border-color: var(--primary-color);
}

/* Badge Hero for Modal */
.badge-hero {
    flex-shrink: 0;
    min-width: 120px;
}

.badge-hero-image {
    width: 100px;
    height: 100px;
    object-fit: contain;
    border-radius: 12px;
    border: 3px solid var(--border-color);
    background: var(--bg-white);
    padding: 8px;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
}

.badge-hero-image:hover {
    transform: scale(1.05);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-lg);
    cursor: pointer;
}

.badge-hero-label {
    font-weight: 500;
}

/* ===== CONTACT SECTION ===== */
.contact-section {
    background: var(--bg-white);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-light);
    border-radius: var(--border-radius);
    transition: transform 0.3s ease;
}

.contact-item:hover {
    transform: translateX(10px);
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.contact-details h5 {
    margin-bottom: 0.25rem;
    color: var(--text-dark);
}

.contact-details p {
    margin: 0;
    color: var(--text-light);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .hero-section {
        padding: 60px 0;
    }

    .section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 2rem;
    }

    .experience-header {
        flex-direction: column;
        gap: 0.5rem;
    }

    .certifications-grid {
        grid-template-columns: 1fr;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* ===== UTILITY CLASSES ===== */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
    border-radius: var(--border-radius);
    padding: 0.75rem 2rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--secondary-color), var(--accent-color));
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}