/* 
 * John Blancuzzi - Personal Tech Portfolio
 * Sleek, Professional, Tech-focused Design
 */

:root {
    --primary-color: #0066cc;
    --secondary-color: #004499;
    --accent-color: #00aaff;
    --graphite: #333333;
    --light-graphite: #555555;
    --electric-blue: #00ccff;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --dark-bg: #1a1a1a;
    --darker-bg: #0d1117;
    --text-light: #f8f9fa;
    --text-muted: #6c757d;
    --border-color: #dee2e6;
    --hover-bg: #f8f9fa;
}

/* Typography */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    line-height: 1.6;
    color: #333;
    background-color: #ffffff;
}

main {
    background-color: #ffffff;
    color: #333333;
}

.container {
    background-color: transparent;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 500;
    line-height: 1.4;
    margin-bottom: 1rem;
    color: #333333;
    letter-spacing: -0.025em;
}

h1 {
    font-size: 2.25rem;
    font-weight: 600;
}

h2 {
    font-size: 1.875rem;
    font-weight: 500;
}

h3 {
    font-size: 1.5rem;
    font-weight: 500;
}

h4 {
    font-size: 1.25rem;
    font-weight: 500;
}

.display-1 {
    font-weight: 600;
    font-size: 3.25rem;
    letter-spacing: -0.025em;
}

.display-2 {
    font-weight: 500;
    font-size: 2.75rem;
    letter-spacing: -0.025em;
}

.display-3 {
    font-weight: 500;
    font-size: 2.25rem;
    letter-spacing: -0.025em;
}

.display-4 {
    font-weight: 500;
    font-size: 1.875rem;
    letter-spacing: -0.025em;
}

.display-5 {
    font-weight: 500;
    font-size: 1.625rem;
    letter-spacing: -0.025em;
}

/* Navigation */
.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
}

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link.active {
    color: var(--electric-blue);
}

/* Hero Section */
.hero,
.hero-section {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--graphite) 100%);
    color: var(--text-light);
    padding: 6rem 0 4rem;
    position: relative;
    overflow: hidden;
}

.bg-gradient {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
}

.hero::before,
.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="%23ffffff" opacity="0.03"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    pointer-events: none;
}

.hero .container,
.hero-section .container {
    position: relative;
    z-index: 1;
}

.hero h1,
.hero-section h1 {
    font-size: 3rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    letter-spacing: -0.025em;
    color: #a0a0a0 !important;
}

.hero .lead,
.hero-section .lead {
    font-size: 1.125rem;
    font-weight: 400;
    opacity: 0.9;
    margin-bottom: 2rem;
    line-height: 1.6;
    color: #999999 !important;
}

.hero p,
.hero-section p {
    color: #999999 !important;
}

/* Breadcrumb Styling */
.hero .breadcrumb,
.hero-section .breadcrumb {
    background: transparent !important;
    padding: 0;
    margin-bottom: 0;
    font-size: 0.9rem;
}

.hero .breadcrumb-item a,
.hero-section .breadcrumb-item a {
    color: rgba(255, 255, 255, 0.7) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.hero .breadcrumb-item a:hover,
.hero-section .breadcrumb-item a:hover {
    color: rgba(255, 255, 255, 0.9) !important;
}

.hero .breadcrumb-item.active,
.hero-section .breadcrumb-item.active {
    color: rgba(255, 255, 255, 0.9) !important;
}

.hero .breadcrumb-item+.breadcrumb-item::before,
.hero-section .breadcrumb-item+.breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.5) !important;
    content: ">" !important;
}

/* Additional breadcrumb overrides for better visibility */
.hero-section.bg-gradient .breadcrumb-item a,
.hero.bg-gradient .breadcrumb-item a {
    color: rgba(255, 255, 255, 0.8) !important;
}

.hero-section.bg-gradient .breadcrumb-item.active,
.hero.bg-gradient .breadcrumb-item.active {
    color: white !important;
}

/* Utility Classes */
.min-vh-30 {
    min-height: 30vh;
}

.min-vh-50 {
    min-height: 50vh;
}

.min-vh-100 {
    min-height: 100vh;
}

/* Buttons */
.btn {
    font-weight: 500;
    padding: 0.625rem 1.5rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    text-transform: none;
    letter-spacing: 0.025em;
    border: 1px solid transparent;
}

.btn-lg {
    padding: 0.75rem 2rem;
    font-size: 1rem;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

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

.btn-primary:hover {
    background: var(--secondary-color);
    border-color: var(--secondary-color);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
}

.btn-outline-light {
    border-width: 2px;
}

.btn-outline-light:hover {
    transform: translateY(-1px);
}

/* Cards */
.card {
    border: none;
    border-radius: 0.5rem;
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.06);
    transition: all 0.2s ease;
    overflow: hidden;
    background-color: #ffffff;
    color: #333333;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.card-header {
    background: var(--hover-bg);
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    color: #333333;
}

.card-body {
    background-color: #ffffff;
    color: #333333;
}

.card-title {
    color: #333333 !important;
}

.card-text {
    color: #555555 !important;
}

/* Form Controls */
.form-control {
    background-color: #ffffff;
    color: #333333;
    border: 1px solid #dee2e6;
}

.form-control:focus {
    background-color: #ffffff;
    color: #333333;
}

/* Search and Filter Areas */
.py-4,
.py-5 {
    background-color: #ffffff;
}

/* Portfolio specific styling */
.hover-card {
    background-color: #ffffff !important;
    color: #333333 !important;
}

.hover-card .card-body {
    background-color: #ffffff !important;
    color: #333333 !important;
}

.hover-card .card-title {
    color: #333333 !important;
}

.hover-card .card-text {
    color: #555555 !important;
}

/* Ensure badges are visible */
.badge {
    color: #ffffff !important;
}

/* Global text visibility overrides */
p,
span,
div,
h1,
h2,
h3,
h4,
h5,
h6 {
    color: inherit;
}

/* Specific text overrides for common cases */
.text-muted {
    color: #6c757d !important;
}

.text-dark {
    color: #333333 !important;
}

/* Ensure all content sections have light backgrounds */
section {
    background-color: #ffffff;
    color: #333333;
}

section.py-5:not(.bg-dark):not(.hero-section):not(.bg-gradient) {
    background-color: #ffffff !important;
    color: #333333 !important;
}

section.bg-light {
    background-color: #f8f9fa !important;
    color: #333333 !important;
}

/* Fix sections that might have transparent backgrounds */
.py-5 {
    background-color: #ffffff;
}

.py-5.bg-light {
    background-color: #f8f9fa !important;
}

/* Emergency text visibility fixes - extremely specific */
.container .row .col-lg-4 .card .card-body,
.container .row .col-md-6 .card .card-body,
.card.hover-card .card-body,
.card .card-body {
    background-color: #ffffff !important;
    color: #333333 !important;
}

.container .row .col-lg-4 .card .card-body h3,
.container .row .col-md-6 .card .card-body h3,
.card.hover-card .card-body h3,
.card .card-body .card-title {
    color: #333333 !important;
}

.container .row .col-lg-4 .card .card-body p,
.container .row .col-md-6 .card .card-body p,
.card.hover-card .card-body p,
.card .card-body .card-text {
    color: #555555 !important;
}

/* Additional card fixes for all card variations */
.card.h-100,
.card.shadow-sm,
.hover-card {
    background-color: #ffffff !important;
    color: #333333 !important;
    border: 1px solid #dee2e6 !important;
}

/* Fix for sections with bg-light */
.bg-light .card,
.bg-light .card-body {
    background-color: #ffffff !important;
    color: #333333 !important;
}

.bg-light .card-title,
.bg-light .card h3,
.bg-light .card h5 {
    color: #333333 !important;
}

.bg-light .card-text,
.bg-light .card p {
    color: #555555 !important;
}

/* Fix for any remaining invisible text */
.card * {
    color: inherit !important;
}

.card h1,
.card h2,
.card h3,
.card h4,
.card h5,
.card h6 {
    color: #333333 !important;
}

.card p,
.card span:not(.badge) {
    color: #555555 !important;
}

/* Container and layout fixes */
.container {
    background-color: transparent !important;
}

.row {
    background-color: transparent !important;
}

/* Homepage and content area fixes */
main {
    background-color: #ffffff !important;
    color: #333333 !important;
}

/* Fix any remaining text visibility issues */
.text-muted {
    color: #6c757d !important;
}

.lead {
    color: inherit !important;
}

/* Skills Section */
.skill-item {
    background: white !important;
    color: #333333 !important;
    border-radius: 0.5rem;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    height: 100%;
}

.skill-item h3,
.skill-item h4,
.skill-item h5 {
    color: #333333 !important;
}

.skill-item p {
    color: #555555 !important;
}

/* Comprehensive Site-Wide Text Visibility Fixes */
/* This ensures all text is visible regardless of template variations */
body *:not(.hero):not(.hero-section):not(.bg-dark):not(.navbar-dark):not(.footer):not(.badge) {
    background-color: inherit;
}

/* Force white backgrounds for all content containers */
.container:not(.hero .container):not(.hero-section .container):not(.bg-dark .container) {
    background-color: transparent !important;
}

/* Ensure all text elements have proper colors */
h1:not(.hero h1):not(.hero-section h1):not(.bg-dark h1):not(.navbar-dark h1),
h2:not(.hero h2):not(.hero-section h2):not(.bg-dark h2):not(.navbar-dark h2),
h3:not(.hero h3):not(.hero-section h3):not(.bg-dark h3):not(.navbar-dark h3),
h4:not(.hero h4):not(.hero-section h4):not(.bg-dark h4):not(.navbar-dark h4),
h5:not(.hero h5):not(.hero-section h5):not(.bg-dark h5):not(.navbar-dark h5),
h6:not(.hero h6):not(.hero-section h6):not(.bg-dark h6):not(.navbar-dark h6) {
    color: #333333 !important;
}

p:not(.hero p):not(.hero-section p):not(.bg-dark p):not(.navbar-dark p):not(.footer p),
div:not(.hero div):not(.hero-section div):not(.bg-dark div):not(.navbar-dark div):not(.footer div),
span:not(.badge):not(.hero span):not(.hero-section span):not(.bg-dark span):not(.navbar-dark span) {
    color: #555555 !important;
}

/* Specific Card Element Fixes */
.card-title,
.card h3,
.card h4,
.card h5,
.card h6 {
    color: #333333 !important;
}

.card-text,
.card p,
.card small {
    color: #555555 !important;
}

/* Small text and muted text visibility */
.text-muted,
.small {
    color: #6c757d !important;
}

/* Ensure Bootstrap utility classes work properly */
.text-danger {
    color: #dc3545 !important;
}

.text-success {
    color: #198754 !important;
}

.skill-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
}

.skill-item .skill-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.progress {
    height: 8px;
    border-radius: 4px;
    background-color: #e9ecef;
}

.progress-bar {
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 4px;
}

/* Portfolio Grid */
.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 0.75rem;
    transition: all 0.3s ease;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
    visibility: visible;
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 102, 204, 0.9);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

/* Services */
.service-card {
    text-align: center;
    padding: 2rem 1.5rem;
    height: 100%;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
    border: 1px solid #e9ecef;
}

.service-card:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-4px);
    border-color: var(--primary-color);
}

.service-card .service-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.service-card:hover .service-icon {
    background: white;
    color: var(--primary-color);
}

/* Testimonials */
.testimonial-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    position: relative;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 2rem;
    font-size: 4rem;
    color: var(--primary-color);
    font-weight: 700;
    line-height: 1;
}

.testimonial-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary-color);
}

/* Contact Form */
.form-control {
    border: 2px solid #e9ecef;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
    font-weight: 400;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 102, 204, 0.1);
}

.form-label {
    font-weight: 600;
    color: var(--graphite);
    margin-bottom: 0.5rem;
}

/* Footer */
.footer {
    background: var(--dark-bg) !important;
}

.footer h5,
.footer h6 {
    color: #a0a0a0 !important;
}

.footer p,
.footer div,
.footer span,
.footer small {
    color: #999999 !important;
}

.footer a {
    text-decoration: none;
    transition: color 0.3s ease;
    color: #999999 !important;
}

.footer a:hover {
    color: var(--electric-blue) !important;
}

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

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

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

/* Utility Classes */
.bg-primary-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
}

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

.border-primary {
    border-color: var(--primary-color) !important;
}

.shadow-custom {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }

    .hero .lead {
        font-size: 1.1rem;
    }

    .btn {
        padding: 0.6rem 1.5rem;
        font-size: 0.9rem;
    }

    .service-card {
        padding: 1.5rem 1rem;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .card {
        background-color: var(--darker-bg);
        color: var(--text-light);
    }

    .form-control {
        background-color: var(--dark-bg);
        border-color: var(--light-graphite);
        color: var(--text-light);
    }
}

/* Print styles */
@media print {

    .navbar,
    .footer,
    .btn {
        display: none !important;
    }

    .hero {
        background: white !important;
        color: black !important;
        padding: 2rem 0 !important;
    }
}

/* EMERGENCY TEXT VISIBILITY FIXES - HIGHEST PRIORITY */
/* These rules override everything to make text visible */

/* Force all content areas to have visible text */
.py-5,
.py-4,
.container,
.row,
.col,
.col-12,
.col-lg-6,
.col-lg-8,
.col-md-8 {
    color: #333333 !important;
}

/* Force all headings to be visible outside of hero sections */
h1:not(.hero h1):not(.hero-section h1):not(.navbar h1):not(.footer h1),
h2:not(.hero h2):not(.hero-section h2):not(.navbar h2):not(.footer h2),
h3:not(.hero h3):not(.hero-section h3):not(.navbar h3):not(.footer h3),
h4:not(.hero h4):not(.hero-section h4):not(.navbar h4):not(.footer h4),
h5:not(.hero h5):not(.hero-section h5):not(.navbar h5):not(.footer h5),
h6:not(.hero h6):not(.hero-section h6):not(.navbar h6):not(.footer h6) {
    color: #333333 !important;
    background: transparent !important;
}

/* Force all paragraphs and text to be visible */
p:not(.hero p):not(.hero-section p):not(.navbar p):not(.footer p),
div:not(.hero div):not(.hero-section div):not(.navbar div):not(.footer div):not(.badge),
span:not(.badge):not(.hero span):not(.hero-section span):not(.navbar span):not(.footer span),
small:not(.hero small):not(.hero-section small):not(.navbar small):not(.footer small),
.card-text,
.card-title,
.text-muted {
    color: #555555 !important;
    background: transparent !important;
}

/* Disable dark mode completely for content areas */
@media (prefers-color-scheme: dark) {

    .py-5 *,
    .py-4 *,
    .container:not(.hero .container):not(.navbar .container):not(.footer .container) * {
        color: #333333 !important;
        background-color: transparent !important;
    }
}

/* Override any text-fill-color that might be causing invisibility */
*:not(.hero *):not(.hero-section *):not(.navbar *):not(.footer *):not(.badge) {
    -webkit-text-fill-color: initial !important;
    background-clip: initial !important;
    -webkit-background-clip: initial !important;
}