/* Updated: 2025-08-31 14:15 - Fixed code formatting and syntax highlighting */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    width: 100%;
    margin: 0;
    padding: 0;
    font-family: Tahoma, Verdana, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: #dddddd;
    background-color: #2b2a2a;
    overflow-x: hidden;
}

/* Responsive typography */
@media (max-width: 576px) {
    body {
        font-size: 13px;
    }

    .display-4 {
        font-size: 2rem !important;
    }

    .display-md-3 {
        font-size: 2.5rem !important;
    }
}

@media (min-width: 768px) {
    .display-md-3 {
        font-size: 3rem !important;
    }
}

/* Card improvements for mobile */
@media (max-width: 576px) {
    .card {
        margin-bottom: 1rem;
    }

    .card-body {
        padding: 1rem 0.75rem;
    }
}

/* Navbar improvements */
@media (max-width: 991px) {
    .navbar-collapse {
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }
}

/* List improvements for mobile */
@media (max-width: 576px) {
    .list-group-item {
        padding: 0.5rem 0;
        font-size: 0.9rem;
    }
}

/* Search functionality styles */
.search-highlight {
    background-color: #ffc107;
    color: #000;
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: bold;
}

.search-result {
    animation: searchPulse 0.5s ease-in-out;
    border-left: 3px solid #ffc107;
    padding-left: 10px;
    margin-left: -10px;
    transition: all 0.3s ease;
}

@keyframes searchPulse {
    0% {
        background-color: rgba(255, 193, 7, 0.3);
    }

    50% {
        background-color: rgba(255, 193, 7, 0.1);
    }

    100% {
        background-color: transparent;
    }
}

/* Search input enhancements */
.form-control[type="search"] {
    transition: all 0.3s ease;
}

.form-control[type="search"]:focus {
    box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.25);
    border-color: #ffc107;
}

/* Search results summary */
#search-results-summary {
    position: relative;
    z-index: 10;
}

#search-results-summary .btn-outline-warning {
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
}

/* Mobile search improvements */
@media (max-width: 576px) {
    .search-result {
        margin-left: -5px;
        padding-left: 5px;
        border-left-width: 2px;
    }

    .search-highlight {
        padding: 1px 3px;
        font-size: 0.9em;
    }

    #search-results-summary {
        font-size: 0.9rem;
    }

    #search-results-summary .btn-outline-warning {
        font-size: 0.75rem;
        padding: 0.2rem 0.4rem;
    }
}

/* Contact form styles */
.form-control:focus,
.form-select:focus {
    border-color: #ffc107;
    box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.25);
}

.form-check-input:checked {
    background-color: #ffc107;
    border-color: #ffc107;
}

.form-check-input:focus {
    border-color: #ffc107;
    box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.25);
}

.is-valid {
    border-color: #198754 !important;
}

.is-invalid {
    border-color: #dc3545 !important;
}

.invalid-feedback {
    display: block;
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Character counter */
#messageCounter {
    font-size: 0.8rem;
    margin-top: 0.25rem;
}

/* Accordion customization */
.accordion-button:not(.collapsed) {
    background-color: rgba(255, 193, 7, 0.1);
    color: #ffc107;
}

.accordion-button:focus {
    border-color: #ffc107;
    box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.25);
}

/* Social media links */
.card-body a {
    color: #ffc107;
    transition: color 0.3s ease;
}

.card-body a:hover {
    color: #ffcd39;
}

/* Mobile improvements for contact form */
@media (max-width: 576px) {

    .form-control,
    .form-select {
        font-size: 16px;
        /* Prevents zoom on iOS */
    }

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

    .accordion-button {
        font-size: 0.9rem;
        padding: 0.75rem;
    }
}



h1,
h2,
h3,
h4,
h5,
h6 {
    color: #ffffff;
    margin: 10px 0 10px 0;
    font-weight: bold;
    padding: 0;
}

/* Code syntax highlighting */
.code-container {
    position: relative;
    background-color: #1e1e1e;
    border-radius: 8px;
    overflow: hidden;
}

.code-with-lines {
    display: flex;
    font-family: 'Courier New', Consolas, 'Liberation Mono', Menlo, Courier, monospace;
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
    background-color: #1e1e1e;
}

.line-numbers {
    background-color: #2d2d2d;
    color: #858585;
    padding: 1rem 0.5rem;
    text-align: right;
    user-select: none;
    border-right: 1px solid #404040;
    min-width: 40px;
}

.code-content {
    flex: 1 !important;
    padding: 1rem !important;
    overflow-x: auto !important;
    background-color: #1e1e1e !important;
    font-family: 'Courier New', Consolas, 'Liberation Mono', Menlo, Courier, monospace !important;
    margin: 0 !important;
    border: none !important;
    white-space: pre !important;
}

/* Java syntax highlighting */
.java-keyword {
    color: #569cd6 !important;
    font-weight: bold !important;
}

.java-class {
    color: #4ec9b0 !important;
}

.java-method {
    color: #dcdcaa !important;
}

.java-string {
    color: #ce9178 !important;
}

.java-comment {
    color: #6a9955 !important;
    font-style: italic !important;
}

.java-bracket {
    color: #ffd700 !important;
}

.java-parenthesis {
    color: #da70d6 !important;
}

.java-number {
    color: #b5cea8 !important;
}

/* Mobile code improvements */
@media (max-width: 576px) {
    .code-with-lines {
        font-size: 12px;
    }

    .line-numbers {
        padding: 0.75rem 0.25rem;
        min-width: 30px;
    }

    .code-content {
        padding: 0.75rem;
    }
}