/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.nav-item {
    margin-bottom: 0 !important ;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 18px;
    line-height: 1.7;
    color: #1a1a1a;
    background-color: #fafafa;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700 !important;
    margin-bottom: 1.2rem !important;
    line-height: 1.3 !important;
    color: #1a1a1a !important;
}

h1 {
    font-size: 3rem !important;
    margin-bottom: 1.5rem !important;
}

h2 {
    font-size: 2.25rem !important;
    margin-top: 2rem !important;
    margin-bottom: 1.5rem !important;
    padding-bottom: 0.75rem !important;
    border-bottom: 3px solid purple !important;
}

h3 {
    font-size: 1.75rem !important;
    margin-top: 1.5rem !important;
    color: purple !important;
}

h4 {
    font-size: 1.5rem !important;
}

h5 {
    font-size: 1.25rem !important;
    font-weight: 600 !important;
}

p {
    font-size: 18px;
    margin-bottom: 1.2rem;
    color: #2c2c2c;
}

/* Navigation */
.navbar {
    background: linear-gradient(135deg, purple 0%, #6b21a8 100%);
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: white !important;
}

.navbar-brand img {
    filter: none !important;
    box-shadow: none !important;
}

.navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    transition: all 0.3s ease;
    list-style: none !important;
}

.navbar-nav .nav-link::before,
.navbar-nav .nav-link::after {
    display: none !important;
}

.navbar-nav .nav-item {
    list-style: none !important;
}

.navbar-nav .nav-item::before,
.navbar-nav .nav-item::after {
    display: none !important;
}

.navbar-nav {
    list-style: none !important;
}

.navbar-nav .nav-link:hover {
    color: white !important;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
}

.navbar-toggler {
    border-color: rgba(255, 255, 255, 0.5);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* CTA Buttons in Nav */
.btn-cta-primary,
.btn-cta-secondary {
    padding: 0.6rem 1.5rem !important;
    font-weight: 600;
    font-size: 16px;
    border-radius: 6px;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    white-space: nowrap;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.btn-cta-primary {
    background-color: tan !important;
    color: #1a1a1a !important;
    border-color: tan !important;
}

.btn-cta-primary:hover {
    background-color: #c19a6b !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(210, 180, 140, 0.4);
}

.btn-cta-secondary {
    background-color: transparent !important;
    color: white !important;
    border-color: white !important;
}

.btn-cta-secondary:hover {
    background-color: white !important;
    color: purple !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.3);
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, tan 0%, #c19a6b 100%) !important;
    padding: 6rem 0 !important;
    margin-bottom: 0 !important;
}

.hero-section h1 {
    color: #1a1a1a !important;
    font-size: 3.5rem !important;
    margin-bottom: 1.5rem !important;
}

.hero-section .hero-text {
    font-size: 1.25rem !important;
    color: #2c2c2c !important;
    margin-bottom: 2rem !important;
    line-height: 1.8 !important;
}

.btn-hero {
    background-color: purple !important;
    color: white !important;
    padding: 1rem 2.5rem !important;
    font-size: 1.1rem !important;
    font-weight: 600 !important;
    border-radius: 8px !important;
    text-decoration: none !important;
    display: inline-block !important;
    transition: all 0.3s ease !important;
    border: none !important;
    white-space: nowrap !important;
}

.btn-hero:hover {
    background-color: #6b21a8 !important;
    color: white !important;
    transform: translateY(-3px) !important;
    box-shadow: 0 6px 20px rgba(128, 0, 128, 0.4) !important;
}

/* Table of Contents Section */
.toc-section {
    background-color: #f5f5f5;
    padding: 3rem 0;
}

.btn-outline-primary {
    color: purple !important;
    border-color: purple !important;
    background-color: white !important;
    padding: 1rem 1.5rem !important;
    font-size: 1.1rem !important;
    font-weight: 500 !important;
    text-align: left !important;
    border-radius: 0 !important;
    border-width: 2px !important;
    transition: all 0.3s ease !important;
    text-decoration: none !important;
}

.btn-outline-primary:hover {
    background-color: purple !important;
    color: white !important;
    border-color: purple !important;
    transform: translateX(10px) !important;
}

.btn-group-vertical {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.btn-group-vertical .btn:first-child {
    border-top-left-radius: 8px !important;
    border-top-right-radius: 8px !important;
}

.btn-group-vertical .btn:last-child {
    border-bottom-left-radius: 8px !important;
    border-bottom-right-radius: 8px !important;
}

/* Content Sections */
.content-section {
    padding: 4rem 0;
    background-color: white;
}

.content-section:nth-of-type(even) {
    background-color: #fafafa;
}

/* Cards */
.card {
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    background-color: white;
}

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

.card-body {
    padding: 2rem;
}

/* Lists */
ul, ol {
    margin-bottom: 1.5rem;
    padding-left: 0;
    list-style: none !important;
}

ul li, ol li {
    position: relative;
    padding-left: 2rem;
    margin-bottom: 0.8rem;
    font-size: 18px;
    line-height: 1.7;
    list-style: none !important;
}

ul li::before {
    content: "" !important;
    position: absolute !important;
    left: 0 !important;
    top: 0.6rem !important;
    width: 10px !important;
    height: 10px !important;
    background-color: purple !important;
    border-radius: 50% !important;
    display: block !important;
}

ol {
    counter-reset: item;
}

ol li::before {
    content: counter(item) !important;
    counter-increment: item !important;
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    background-color: purple !important;
    color: white !important;
    width: 24px !important;
    height: 24px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-weight: 600 !important;
    font-size: 14px !important;
}

/* Remove markers from navbar and footer */
.navbar ul,
.navbar ul li,
.footer ul,
.footer ul li,
.footer-links,
.footer-links li {
    list-style: none !important;
    padding-left: 0 !important;
}

.navbar ul li::before,
.navbar ul li::after,
.footer ul li::before,
.footer ul li::after,
.footer-links li::before,
.footer-links li::after {
    display: none !important;
    content: none !important;
}

/* Tables */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 1.5rem;
}

.table {
    width: 100%;
    margin-bottom: 0;
    font-size: 18px;
}

.table thead th {
    background-color: purple;
    color: white;
    font-weight: 600;
    padding: 1rem;
    border: none;
}

.table tbody td {
    padding: 1rem;
    border-bottom: 1px solid #e0e0e0;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(210, 180, 140, 0.1);
}

/* Images */
img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

picture img {
    display: block;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, #2d1b4e 0%, purple 100%);
    color: white;
    padding: 3rem 0 1.5rem;
    margin-top: 4rem;
}

.footer h5 {
    color: tan !important;
    margin-bottom: 1.5rem !important;
    font-weight: 600 !important;
}

.footer-brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: white;
}

.footer p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 16px;
}

.footer-links {
    padding-left: 0 !important;
    list-style: none !important;
}

.footer-links li {
    margin-bottom: 0.8rem;
    padding-left: 0 !important;
}

.footer-links li::before,
.footer-links li::after {
    display: none !important;
    content: none !important;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 16px;
}

.footer-links a:hover {
    color: tan;
}

.footer .border-top {
    border-color: rgba(255, 255, 255, 0.2) !important;
}

/* Responsive Design */
@media (max-width: 991px) {
    h1 {
        font-size: 2.5rem !important;
    }

    h2 {
        font-size: 2rem !important;
    }

    h3 {
        font-size: 1.5rem !important;
    }

    .hero-section {
        padding: 4rem 0 !important;
    }

    .hero-section h1 {
        font-size: 2.5rem !important;
    }

    .hero-section .hero-text {
        font-size: 1.1rem !important;
    }

    .content-section {
        padding: 3rem 0;
    }

    .navbar-nav {
        margin-top: 1rem;
    }

    .btn-cta-primary,
    .btn-cta-secondary {
        width: 100%;
        margin-bottom: 0.5rem;
    }
}

@media (max-width: 767px) {
    body {
        font-size: 16px;
    }

    h1 {
        font-size: 2rem !important;
    }

    h2 {
        font-size: 1.75rem !important;
    }

    h3 {
        font-size: 1.35rem !important;
    }

    p, ul li, ol li, .table {
        font-size: 16px;
    }

    .hero-section h1 {
        font-size: 2rem !important;
    }

    .hero-section .hero-text {
        font-size: 1rem !important;
    }

    .btn-hero {
        padding: 0.9rem 2rem !important;
        font-size: 1rem !important;
    }

    .btn-outline-primary {
        font-size: 1rem !important;
        padding: 0.9rem 1.2rem !important;
    }

    .card-body {
        padding: 1.5rem;
    }

    .content-section {
        padding: 2.5rem 0;
    }

    .toc-section {
        padding: 2rem 0;
    }

    .footer {
        padding: 2rem 0 1rem;
    }
}

/* Contrast and Readability */
strong {
    font-weight: 600;
    color: #1a1a1a;
}

em {
    font-style: italic;
    color: purple;
}

a {
    color: purple;
    transition: color 0.3s ease;
}

a:hover {
    color: #6b21a8;
    text-decoration: underline;
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Additional spacing for anchored sections */
section[id] {
    scroll-margin-top: 80px;
}
