header {
    background-color: white;
}

nav {
    margin-left: auto;
    margin-right: auto;
    display: flex;
    max-width: 80rem;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 1rem;
}

@media (min-width: 1024px) {
    nav {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

.nav-container {
    display: flex;
    flex: 1;
}

.nav-links {
    display: none;
    gap: 2rem;
}

@media (min-width: 1024px) {
    .nav-links {
        display: flex;
    }
}

.nav-link {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    font-size: 0.75rem;
    line-height: 1.5rem;
    font-weight: 600;
    color: #111827;
    text-decoration: none;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: #4b5563;
}

.mobile-menu-button {
    display: flex;
}

@media (min-width: 1024px) {
    .mobile-menu-button {
        display: none;
    }
}

.menu-toggle-btn {
    margin: -0.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.375rem;
    padding: 0.25rem;
    color: #374151;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.menu-toggle-btn:hover {
    color: #111827;
    background-color: #f3f4f6;
}

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

.icon {
    width: 3rem;
    height: 1.5rem;
}

.logo-link {
    margin: -0.125rem;
    padding: 0.125rem;
    display: block;
}

.logo-img {
    height: 4rem;
    width: auto;
    display: block;
}

.nav-end {
    display: flex;
    flex: 1;
    justify-content: flex-end;
}

dialog {
    margin: 0;
    padding: 0;
}

dialog::backdrop {
    background-color: rgba(0, 0, 0, 0.5);
}

@media (min-width: 1024px) {
    #mobile-menu {
        display: none;
    }
}

.dialog-overlay {
    position: fixed;
    inset: 0;
    outline: none;
}

.dialog-overlay:focus {
    outline: 2px solid transparent;
    outline-offset: 2px;
}

.dialog-panel {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 10;
    width: 100%;
    max-width: 24rem;
    overflow-y: auto;
    background-color: white;
    padding: 0.75rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.dialog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.dialog-close-btn {
    margin: -0.25rem;
    border-radius: 0.375rem;
    padding: 0.25rem;
    color: #374151;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.dialog-close-btn:hover {
    color: #111827;
    background-color: #f3f4f6;
}

.mobile-menu-links {
    margin-top: 0.75rem;
}

.mobile-menu-links > * + * {
    margin-top: 0.5rem;
}

.mobile-menu-link {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    margin-left: -0.5rem;
    margin-right: -0.5rem;
    display: block;
    border-radius: 0.5rem;
    padding: 0.375rem 0.5rem;
    font-size: 0.75rem;
    line-height: 1.75rem;
    font-weight: 600;
    color: #111827;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.mobile-menu-link:hover {
    background-color: #f9fafb;
}

.nav-links {
    align-items: center;
}

.nav-dropdown {
    position: relative;
}

.nav-dropdown-toggle {
    background-color: transparent;
    border: none;
    cursor: pointer;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    color: #111827;
    text-decoration: none;
    transition: color 0.2s ease;
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 12rem;
    margin-top: 0.5rem;
    padding: 0.5rem 0;
    background-color: #ffffff;
    border-radius: 0.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transform: translateY(6px);
    pointer-events: none;
    transition: opacity 0.18s ease, transform 0.18s ease;
    z-index: 20;
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.nav-dropdown-menu a {
    display: block;
    padding: 0.4rem 0.9rem;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    font-size: 0.75rem;
    font-weight: 500;
    color: #111827;
    text-decoration: none;
    white-space: nowrap;
}

.nav-dropdown-menu a:hover {
    background-color: #f3f4f6;
}

@media (max-width: 1023px) {
    .nav-dropdown-menu {
        position: static;
        margin-top: 0.25rem;
        box-shadow: none;
        border-radius: 0.25rem;
    }
}

.nav-actions {
    margin-left: auto;
    margin-right: 2rem;
}